-
-
Notifications
You must be signed in to change notification settings - Fork 517
39 lines (33 loc) · 1.06 KB
/
modlist.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
name: Update Modlist
on:
push:
branches:
- 'develop'
- 'modlist/**'
paths:
- MODLIST.md
- minecraftinstance.json
- automation/settings.ps1
- .github/workflows/modlist.yml
- automation/node/modlist-generate.js
jobs:
job:
runs-on: ubuntu-latest
timeout-minutes: 20
steps:
- uses: actions/checkout@v3
with:
fetch-depth: 0
- uses: actions/setup-node@v3
- run: npm install
working-directory: automation/node
- run: node automation/node/modlist-generate.js
- name: Run git commit
run: |
git config user.name "$(git log -n 1 --pretty=format:%an minecraftinstance.json)"
git config user.email "$(git log -n 1 --pretty=format:%ae minecraftinstance.json)"
git diff --exit-code MODLIST.md || (git add MODLIST.md && git commit -m "Update MODLIST.md")
git push
env:
GIT_COMMITTER_NAME: github-actions[bot]
GIT_COMMITTER_EMAIL: 41898282+github-actions[bot]@users.noreply.github.com