merge #2
This file contains hidden or 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
| name: Release to PPA | |
| on: | |
| push: | |
| branches: | |
| - ppa_ci | |
| tags: | |
| - 'v*' | |
| workflow_dispatch: | |
| jobs: | |
| build_and_upload: | |
| runs-on: ubuntu-latest | |
| steps: | |
| - name: Checkout code | |
| uses: actions/checkout@v4 | |
| with: | |
| fetch-depth: 0 | |
| submodules: recursive | |
| - name: Install dependencies | |
| run: | | |
| sudo apt-get update | |
| sudo apt-get install -y git-buildpackage debhelper devscripts dput dh-cmake libglm-dev libglfw3-dev libpng-dev libjpeg-dev libeigen3-dev | |
| - name: Import GPG key | |
| uses: crazy-max/ghaction-import-gpg@v6 | |
| with: | |
| gpg_private_key: ${{ secrets.GPG_PRIVATE_KEY_B64 }} | |
| passphrase: ${{ secrets.GPG_PASSPHRASE }} | |
| git_user_signingkey: true | |
| git_commit_gpgsign: true | |
| - name: Configure Git | |
| run: | | |
| git config --global user.name "GitHub Action" | |
| git config --global user.email "[email protected]" | |
| - name: Build Source Package | |
| run: | | |
| git checkout debian | |
| gbp buildpackage -S -sa \ | |
| --git-upstream-tag='v%(version)s' \ | |
| --git-submodules \ | |
| --git-ignore-branch | |
| - name: Upload to Launchpad PPA | |
| env: | |
| PPA_TARGET: ${{ secrets.LP_PPA }} | |
| run: | | |
| echo "[my-ppa]" > dput.cf | |
| echo "fqdn = ppa.launchpad.net" >> dput.cf | |
| echo "method = ftp" >> dput.cf | |
| echo "incoming = ~${PPA_TARGET#ppa:}/ubuntu/" >> dput.cf | |
| echo "login = anonymous" >> dput.cf | |
| echo "allow_unsigned_uploads = 0" >> dput.cf | |
| dput -c dput.cf my-ppa ../*.changes |