Update AUR #5
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: Update AUR | |
on: | |
workflow_dispatch: | |
workflow_run: | |
workflows: ['Release'] | |
types: | |
- completed | |
jobs: | |
run_on_release_success: | |
runs-on: ubuntu-latest | |
if: ${{ github.event_name == 'workflow_dispatch' || github.event.workflow_run.conclusion == 'success' }} | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v4 | |
- name: Setup git auth | |
run: | | |
mkdir -p ~/.ssh | |
echo "${{ secrets.AUR_SSH_PRIVATE_KEY }}" > ~/.ssh/aur | |
chmod 600 ~/.ssh/aur | |
echo -e "Host aur.archlinux.org\n IdentityFile ~/.ssh/aur\n User aur\n StrictHostKeyChecking=no" > ~/.ssh/config | |
git config --global user.name "${{ secrets.AUR_USERNAME }}" | |
git config --global user.email "${{ secrets.AUR_EMAIL }}" | |
- name: Clone AUR | |
run: | | |
git clone ssh://[email protected]/capter.git | |
- name: Update AUR | |
uses: heyhusen/archlinux-package-action@v2 | |
with: | |
path: capter | |
flags: '--nodeps --nobuild' | |
namcap: false | |
srcinfo: true | |
- name: Push Update | |
run: | | |
cd capter | |
git add PKGBUILD .SRCINFO | |
git commit -m "Update: ${{ github.ref_name }}" || echo "No changes !!" | |
git push --force |