feat(ci): improve workflows

This commit is contained in:
windowsboy111
2023-03-16 18:56:03 +08:00
parent 2b8d6207ea
commit df95dd3dfb
6 changed files with 33 additions and 92 deletions
+8 -5
View File
@@ -1,6 +1,3 @@
# for each folder in ultramarine/
# if there is chkupdate.py
# run it every 2 hours
name: Automatically check for updates
on:
schedule:
@@ -11,7 +8,7 @@ jobs:
autoupdate:
runs-on: ubuntu-latest
container:
image: ghcr.io/terrapkg/builder:f38
image: ghcr.io/terrapkg/builder:main
options: --cap-add=SYS_ADMIN --privileged
steps:
- name: Checkout
@@ -40,6 +37,12 @@ jobs:
git config user.email "raboneko@fyralabs.com"
git config gpg.format "ssh"
git config user.signingkey "${{ runner.temp }}/signing_key"
git commit -S -a -m "Automatic Update: $(git status | grep modified | sed -r 's@.+/([^/]+)/[^/]+\n?@\1 @g' | tr -d '\n')"
msg="bump: $(git status | grep modified | sed -r 's@.+/([^/]+)/[^/]+\n?@\1 @g' | tr -d '\n')"
git commit -S -a -m $msg
git format-patch HEAD^
git checkout f38
git apply *.patch
rm *.patch
git commit -S -a -m $msg
git push -u origin f38
fi