generated from MechanicalFlower/godot-template
-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
ci: enable snapcraft packaging (#22)
* ci: refactor snapcraft * fix: update the icon * chore: add changelog entry * fix style
- Loading branch information
1 parent
29f5020
commit 0903c35
Showing
8 changed files
with
147 additions
and
52 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,29 +1,46 @@ | ||
|
||
name: "Snapcraft build" | ||
name: Snapcraft Build | ||
|
||
on: | ||
push: | ||
workflow_dispatch: | ||
|
||
jobs: | ||
build: | ||
runs-on: ubuntu-latest | ||
runs-on: ubuntu-22.04 | ||
timeout-minutes: 30 | ||
|
||
steps: | ||
- name: Checkout repository | ||
uses: actions/checkout@v4 | ||
- uses: actions/checkout@v4 | ||
- uses: extractions/setup-just@v1 | ||
|
||
- name: Load dotenv | ||
run: just bump-version | ||
|
||
- name: Build snap package | ||
uses: snapcore/action-build@v1 | ||
id: snapcraft | ||
- name: Build snap package | ||
uses: snapcore/action-build@v1 | ||
working-directory: public/packaging | ||
id: snapcraft | ||
|
||
- name: Install built snap package | ||
run: | | ||
sudo snap install --dangerous ${{ steps.snapcraft.outputs.snap }} | ||
# Push, on each commit of the main branch, to the edge channel | ||
- uses: snapcore/action-publish@v1 | ||
if: github.ref == 'refs/heads/main' | ||
env: | ||
SNAPCRAFT_STORE_CREDENTIALS: ${{ secrets.SNAP_STORE_LOGIN }} | ||
with: | ||
snap: ${{ steps.snapcraft.outputs.snap }} | ||
release: edge | ||
|
||
- name: Install dependencies for test launch | ||
run: | | ||
sudo apt install -y mesa-utils libgl1-mesa-dri libglx-mesa0 | ||
- name: Update the snapcraft to be stable | ||
if: startsWith(github.ref, 'refs/tags/') | ||
run: | | ||
sed -i "s,grade:\ devel$,grade:\ stable\",g" ./public/packaging/snap/snapcraft.yaml | ||
sed -i "s,confinement:\ devmode$,confinement:\ strict,g" ./public/packaging/snap/snapcraft.yaml | ||
- name: Test marble launch | ||
uses: GabrielBB/[email protected] | ||
with: | ||
run: /bin/bash public/packaging/snap/snap-xvfb-launch.sh | ||
# Push, on each tag, to the stable channel | ||
- uses: snapcore/action-publish@v1 | ||
if: startsWith(github.ref, 'refs/tags/') | ||
env: | ||
SNAPCRAFT_STORE_CREDENTIALS: ${{ secrets.SNAP_STORE_LOGIN }} | ||
with: | ||
snap: ${{ steps.snapcraft.outputs.snap }} | ||
release: stable |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1 +1,2 @@ | ||
*.import | ||
*.snap |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,6 @@ | ||
|
||
[Desktop Entry] | ||
Version=1.3 | ||
Version=1.4.2 | ||
Type=Application | ||
|
||
Name=Marble | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters