Skip to content

Update mods

Update mods #3034

Workflow file for this run

name: Update mods
on:
workflow_dispatch:
schedule:
- cron: '0 0 * * *'
jobs:
update:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Set up Go
uses: actions/setup-go@v4
with:
go-version: 'stable'
- name: Install packwiz
run: go install github.com/packwiz/packwiz@latest
- name: Prepare update log
run: |
echo 'Updating mods' > update.log
echo '```' >> update.log
- name: Update mods
run: packwiz update -y --all 2>&1 | tee -a update.log
- name: Close out update log
run: echo '```' >> update.log
- name: Set commit message
id: commit_message
run: |
echo 'commit_message<<EOF' >> $GITHUB_OUTPUT
cat update.log >> $GITHUB_OUTPUT
echo 'EOF' >> $GITHUB_OUTPUT
- name: Delete update log file
run: rm -f update.log
- name: Commit and push if changes
uses: stefanzweifel/git-auto-commit-action@v5
with:
commit_message: ${{ steps.commit_message.outputs.commit_message }}