mirror of
https://github.com/gaoyifan/china-operator-ip.git
synced 2025-07-14 05:12:28 +08:00
use github personal access tokens for CI deploy
This commit is contained in:
parent
14e46088a9
commit
e6ab4095b0
14
upload.sh
14
upload.sh
@ -1,6 +1,12 @@
|
||||
#!/usr/bin/env bash
|
||||
|
||||
git remote set-url origin "https://${GITHUB_USERNAME}:${GITHUB_PASSWORD}@github.com/gaoyifan/china-operator-ip.git"
|
||||
git add result
|
||||
git commit -m "update `date +%Y-%m-%d`"
|
||||
git push origin $(git rev-parse HEAD):${TRAVIS_BRANCH}
|
||||
git config user.name $GIT_USER_NAME
|
||||
git config user.email $GIT_USER_EMAIL
|
||||
|
||||
git clone -b ip-lists https://${GH_REF} ip-lists
|
||||
mv result/* ip-lists
|
||||
cd ip-lists
|
||||
git add .
|
||||
git commit -m "update $(date +%Y-%m-%d)"
|
||||
git push -q "https://${GH_TOKEN}@${GH_REF}" ip-lists:ip-lists
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user