From 0291506fbfd634900b9f6d87d480d18353356831 Mon Sep 17 00:00:00 2001 From: Kevin Yue Date: Mon, 25 Oct 2021 09:27:07 +0800 Subject: [PATCH] update PPA packaging --- .github/workflows/build.yml | 66 ++++++++----------------------------- 1 file changed, 13 insertions(+), 53 deletions(-) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 0188d0e..a382f4d 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -67,64 +67,24 @@ jobs: with: name: snapshot-source-code path: artifacts - - - name: Import GPG key - id: import_gpg - uses: crazy-max/ghaction-import-gpg@v4 - with: - gpg_private_key: ${{ secrets.PPA_GPG_PRIVATE_KEY }} - passphrase: ${{ secrets.PPA_GPG_PASSPHRASE }} - - name: Install dependencies - run: | - sudo apt update - sudo apt install debmake debhelper cmake \ - libqt5websockets5-dev qtbase5-dev qtwebengine5-dev - - - name: Build deb package for 18.04 + - name: Extract source code run: | cd $GITHUB_WORKSPACE/artifacts - mkdir build-18.04 - cp *.tar.gz build-18.04 && cd build-18.04 + mkdir deb-build + cp *.tar.gz deb-build && cd deb-build tar xf *.tar.gz - cd globalprotect-openconnect-*/ - - PPA_GPG_PASSPHRASE=${{ secrets.PPA_GPG_PASSPHRASE }} \ - PPA_GPG_KEYID=${{ steps.import_gpg.outputs.keyid }} ./scripts/ppa-publish.sh 18.04 - - - name: Build deb package for 20.04 - run: | - cd $GITHUB_WORKSPACE/artifacts - mkdir build-20.04 - cp *.tar.gz build-20.04 && cd build-20.04 - tar xf *.tar.gz - cd globalprotect-openconnect-*/ - - PPA_GPG_PASSPHRASE=${{ secrets.PPA_GPG_PASSPHRASE }} \ - PPA_GPG_KEYID=${{ steps.import_gpg.outputs.keyid }} ./scripts/ppa-publish.sh 20.04 - - - name: Build deb package for 21.04 - run: | - cd $GITHUB_WORKSPACE/artifacts - mkdir build-21.04 - cp *.tar.gz build-21.04 && cd build-21.04 - tar xf *.tar.gz - cd globalprotect-openconnect-*/ - - PPA_GPG_PASSPHRASE=${{ secrets.PPA_GPG_PASSPHRASE }} \ - PPA_GPG_KEYID=${{ steps.import_gpg.outputs.keyid }} ./scripts/ppa-publish.sh 21.04 - - - name: Build deb package for 21.10 - run: | - cd $GITHUB_WORKSPACE/artifacts - mkdir build-21.10 - cp *.tar.gz build-21.10 && cd build-21.10 - tar xf *.tar.gz - cd globalprotect-openconnect-*/ - - PPA_GPG_PASSPHRASE=${{ secrets.PPA_GPG_PASSPHRASE }} \ - PPA_GPG_KEYID=${{ steps.import_gpg.outputs.keyid }} ./scripts/ppa-publish.sh 21.10 + - name: Publish PPA + uses: yuezk/publish-ppa-package@develop + with: + repository: 'ppa:yuezk/globalprotect-openconnect-snapshot' + gpg_private_key: ${{ secrets.PPA_GPG_PRIVATE_KEY }} + gpg_passphrase: ${{ secrets.PPA_GPG_PASSPHRASE }} + pkgdir: '${{ github.workspace }}/artifacts/deb-build/globalprotect-openconnect*/' + is_native: true + series: 'bionic focal' + snapshot-aur: if: ${{ github.event_name != 'pull_request' && github.ref == 'refs/heads/develop' }} needs: snapshot-archive-all