mirror of
https://github.com/SagerNet/sing-geosite.git
synced 2025-12-16 22:33:13 +08:00
Generate new rule-sets
This commit is contained in:
25
.github/release-rule-set.sh
vendored
25
.github/release-rule-set.sh
vendored
@@ -2,12 +2,19 @@
|
||||
|
||||
set -e -o pipefail
|
||||
|
||||
cd rule-set
|
||||
git init
|
||||
git config --local user.email "github-action@users.noreply.github.com"
|
||||
git config --local user.name "GitHub Action"
|
||||
git remote add origin https://github-action:$GITHUB_TOKEN@github.com/SagerNet/sing-geosite.git
|
||||
git branch -M rule-set
|
||||
git add .
|
||||
git commit -m "Update rule-set"
|
||||
git push -f origin rule-set
|
||||
function releaseRuleSet() {
|
||||
dirName=$1
|
||||
pushd $dirName
|
||||
git init
|
||||
git config --local user.email "github-action@users.noreply.github.com"
|
||||
git config --local user.name "GitHub Action"
|
||||
git remote add origin https://github-action:$GITHUB_TOKEN@github.com/SagerNet/sing-geosite.git
|
||||
git branch -M $dirName
|
||||
git add .
|
||||
git commit -m "Update rule-set"
|
||||
git push -f origin $dirName
|
||||
popd
|
||||
}
|
||||
|
||||
releaseRuleSet rule-set
|
||||
releaseRuleSet rule-set-unstable
|
||||
|
||||
Reference in New Issue
Block a user