Skip to content

Commit d27867f

Browse files
committed
Move snap publishing to own workflow
1 parent cd70746 commit d27867f

File tree

2 files changed

+26
-14
lines changed

2 files changed

+26
-14
lines changed

.github/workflows/deployment.yml

Lines changed: 0 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -103,20 +103,6 @@ jobs:
103103
export BADASS_JLINK_JPACKAGE_HOME="${GITHUB_WORKSPACE}${{ matrix.jdk14Path }}"
104104
./gradlew -PprojVersion="${{ steps.gitversion.outputs.AssemblySemVer }}" -PprojVersionInfo="${{ steps.gitversion.outputs.InformationalVersion }}" jpackage
105105
shell: bash
106-
- name: Package application image
107-
run: ${{ matrix.archivePortable }}
108-
shell: bash
109-
- name: Build snap (1) Run build
110-
uses: jhenstridge/snapcraft-build-action@v1
111-
id: snapcraft
112-
if: matrix.displayName == 'linux' && startsWith(github.ref,'refs/heads/master')
113-
- name: Build snap (2) Upload snap
114-
uses: jhenstridge/snapcraft-publish-action@v1
115-
with:
116-
store_login: ${{ secrets.SNAPCRAFT_LOGIN_FILE }}
117-
snap: ${{ steps.snapcraft.outputs.snap }}
118-
release: edge
119-
if: matrix.displayName == 'linux' && startsWith(github.ref,'refs/heads/master')
120106
- name: Rename files
121107
run: |
122108
get-childitem -Path build/distribution/* | rename-item -NewName {$_.name -replace "${{ steps.gitversion.outputs.AssemblySemVer }}","${{ steps.gitversion.outputs.Major }}.${{ steps.gitversion.outputs.Minor }}"}

.github/workflows/snap.yml

Lines changed: 26 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,26 @@
1+
name: Snap
2+
3+
on:
4+
schedule:
5+
# run on each day
6+
- cron: '33 4 * * *'
7+
8+
jobs:
9+
build:
10+
runs-on: ubuntu-latest
11+
name: Create snapcraft image
12+
13+
steps:
14+
- name: Checkout source
15+
uses: actions/checkout@v2
16+
# The image relies on https://builds.jabref.org/master/JabRef-5.0-portable_linux.tar.gz^
17+
# See snap/snapcraft.yml for details
18+
- name: Build snap (1) Run build
19+
uses: jhenstridge/snapcraft-build-action@v1
20+
id: snapcraft
21+
- name: Build snap (2) Upload snap
22+
uses: jhenstridge/snapcraft-publish-action@v1
23+
with:
24+
store_login: ${{ secrets.SNAPCRAFT_LOGIN_FILE }}
25+
snap: ${{ steps.snapcraft.outputs.snap }}
26+
release: edge

0 commit comments

Comments
 (0)