diff --git a/.gitea/workflows/build.yml b/.gitea/workflows/build.yml deleted file mode 100644 index 2629395..0000000 --- a/.gitea/workflows/build.yml +++ /dev/null @@ -1,30 +0,0 @@ -name: Build and Push -on: - push: - branches: - - master - -jobs: - build: - runs-on: ubuntu-amd64 - container: - image: gitea.seeseepuff.be/archlinux/archlinux:latest - steps: - - name: Checkout code - uses: actions/checkout@v2 - - - name: Ensure image is up-to-date - run: | - sudo pacman -Syu --noconfirm - - - name: Build package - run: | - makepkg -s --noconfirm - - - - name: Push to repository - run: | - makepkg --packagelist | while read -r file; do - curl --user ${{ secrets.USERNAME }}:${{ secrets.PASSWORD }} \ - --upload-file $file \ - https://gitea.seeseepuff.be/api/packages/archlinux/arch/personal - done diff --git a/.gitea/workflows/update_wake.yml b/.gitea/workflows/update_wake.yml deleted file mode 100644 index 0f872f1..0000000 --- a/.gitea/workflows/update_wake.yml +++ /dev/null @@ -1,36 +0,0 @@ -name: Update repository and wake runner -on: - push: - branches: - - master - -jobs: - update: - runs-on: ubuntu-latest - steps: - - name: Checkout code - uses: actions/checkout@v2 - - - name: Configure Git - run: | - git config user.email "sebastiaan.de.schaetzen+archlinux@gmail.com" - git config user.name "Sebastiaan de Schaetzen (automated)" - - - name: Add AUR repository - run: git remote add aur https://aur.archlinux.org/yay.git - - - name: Fetch AUR - run: git fetch aur - - - name: Rebase current changes - run: git rebase aur/master - - - name: Push changes (if any) - run: git push -f origin master - - wake: - runs-on: ubuntu-latest - steps: - - name: Wakeup Runner - run: | - curl https://idlesleep.wolproxy.seeseepuff.be/status \ No newline at end of file diff --git a/.gitea/workflows/workflow.yml b/.gitea/workflows/workflow.yml new file mode 100644 index 0000000..95c7e7f --- /dev/null +++ b/.gitea/workflows/workflow.yml @@ -0,0 +1,64 @@ +on: + push: + branches: + - master + +jobs: + update: + name: Update from AUR + runs-on: ubuntu-latest + steps: + - name: Checkout code + uses: actions/checkout@v2 + + - name: Configure Git + run: | + git config user.email "sebastiaan.de.schaetzen+archlinux@gmail.com" + git config user.name "Sebastiaan de Schaetzen (automated)" + + - name: Add AUR repository + run: git remote add aur https://aur.archlinux.org/yay.git + + - name: Fetch AUR + run: git fetch aur + + - name: Rebase current changes + run: git rebase aur/master + + - name: Push changes (if any) + run: git push -f origin master + + wake: + name: Wake Runner + runs-on: ubuntu-latest + needs: update + steps: + - name: Wakeup Runner + run: | + curl https://idlesleep.wolproxy.seeseepuff.be/status + + build: + name: Build and Push + runs-on: ubuntu-amd64 + needs: wake + container: + image: gitea.seeseepuff.be/archlinux/archlinux:latest + steps: + - name: Checkout code + uses: actions/checkout@v2 + + - name: Ensure image is up-to-date + run: | + sudo pacman -Syu --noconfirm + + - name: Build package + run: | + makepkg -s --noconfirm - + + - name: Push to repository + run: | + makepkg --packagelist | while read -r file; do + curl --user ${{ secrets.USERNAME }}:${{ secrets.PASSWORD }} \ + --upload-file $file \ + https://gitea.seeseepuff.be/api/packages/archlinux/arch/personal + done