1
0
mirror of https://github.com/SpaceVim/SpaceVim.git synced 2025-03-22 17:05:42 +08:00

Use mirror (#4444)

This commit is contained in:
Wang Shidong 2021-08-29 00:33:12 +08:00 committed by GitHub
parent b80606aec5
commit 0c29068182
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 25 additions and 25 deletions

View File

@ -4,18 +4,18 @@ usage () {
echo ".ci/update_remote.sh [option] [target]" echo ".ci/update_remote.sh [option] [target]"
} }
check_remote () {
if [ -z "$(git remote -v | grep git@gitee.com:spacevim/SpaceVim.git)" ];then
git remote add gitee git@gitee.com:spacevim/SpaceVim.git
fi
}
push_gitee() push_gitee()
{ {
git remote add gitee https://SpaceVimBot:${BOTSECRET}@gitee.com/spacevim/SpaceVim.git git remote add gitee https://SpaceVimBot:${BOTSECRET}@gitee.com/spacevim/SpaceVim.git
git push gitee master git push gitee master
} }
push_gitlab()
{
git remote add gitlab https://SpaceVimBot:${BOTSECRET}@gitlab.com/SpaceVim/SpaceVim.git
git push gitlab master
}
push_coding() push_coding()
{ {
git remote add coding https://spacevim%40outlook.com:${CODINGBOTSECRET}@e.coding.net/spacevim/SpaceVim.git git remote add coding https://spacevim%40outlook.com:${CODINGBOTSECRET}@e.coding.net/spacevim/SpaceVim.git
@ -23,24 +23,24 @@ push_coding()
} }
main () { main () {
if [ $# -gt 0 ] case $1 in
check_remote --help|-h)
then usage
case $1 in exit 0
--help|-h) ;;
usage gitee)
exit 0 push_gitee
;; exit 0
gitee) ;;
push_gitee gitlab)
exit 0 push_gitlab
;; exit 0
coding) ;;
push_coding coding)
exit 0 push_coding
;; exit 0
esac ;;
fi esac
} }
main $@ main $@

View File

@ -7,7 +7,7 @@ jobs:
strategy: strategy:
fail-fast: false fail-fast: false
matrix: matrix:
mirror: ["gitee", "coding"] mirror: ["gitee", "coding", "gitlab"]
runs-on: ubuntu-latest runs-on: ubuntu-latest
steps: steps:
- name: Checkout - name: Checkout