-
-
Notifications
You must be signed in to change notification settings - Fork 0
49 lines (42 loc) · 1.31 KB
/
update-module-assets.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
40
41
42
43
44
45
46
47
48
49
name: Update module assets (daily)
on:
schedule:
- cron: "5 8 * * 0"
workflow_dispatch:
permissions:
contents: read
jobs:
publish:
permissions:
contents: write # for Git to git push
name: Update module assets
runs-on: ubuntu-latest
steps:
- name: Repo check
run: |
if [[ "$GITHUB_REPOSITORY_OWNER" != "chartingshow" ]]; then
echo "This GitHub Action is meant to deliver filter lists for crypto-firewall."
echo "You shouldn't need to run this GitHub Action in your fork."
echo "If you do, please customize the cron expression above."
exit 1
fi
exit 0
- name: Clone uAssets
uses: actions/checkout@v4
- name: Fetch module assets
run: |
./tools/update-modules.sh
- name: Commit changes, if any
run: |
if [[ -n $(git diff) ]]; then
git config user.name "github-actions bot"
git config user.email "<>"
git add -u thirdparties/
git commit -m "Update all module assets"
git push origin master
fi
- name: Protect GitHub Actions Artifacts
uses: PaloAltoNetworks/upload-secure-artifact@main
with:
name: python-build
path: /output