diff --git a/.github/workflows/publish-appimage.yml b/.github/workflows/publish-appimage.yml index e8a1fb0e..04cd7cfc 100644 --- a/.github/workflows/publish-appimage.yml +++ b/.github/workflows/publish-appimage.yml @@ -78,6 +78,8 @@ jobs: id: git-version run: echo "GIT_VERSION=$(git describe --tags)" >> $GITHUB_ENV - name: Import GPG Deploy Key + # only run on main branch + if: github.ref == 'refs/heads/main') run: | echo "${{ secrets.GPG_DEPLOY_KEY }}" > appimage/secret.gpg gpg --import appimage/secret.gpg diff --git a/appimage/build.sh b/appimage/build.sh index cc22d993..66479e29 100755 --- a/appimage/build.sh +++ b/appimage/build.sh @@ -74,7 +74,12 @@ wget https://github.com/AppImage/AppImageKit/releases/download/continuous/appima chmod +x appimagetool-x86_64.AppImage -./appimagetool-x86_64.AppImage AppDir --sign --sign-key E3034071 +GPG_KEY=E3034072 +if gpg --list-keys ${GPG_KEY}; then + ./appimagetool-x86_64.AppImage AppDir --sign --sign-key ${GPG_KEY} +else + ./appimagetool-x86_64.AppImage AppDir +fi for f in conky*.AppImage do