1
0
mirror of https://github.com/SpaceVim/SpaceVim.git synced 2025-01-23 04:10:05 +08:00
SpaceVim/.ci/update_mirror.sh
2024-07-09 00:14:15 +08:00

47 lines
850 B
Bash
Executable File

#!/usr/bin/env bash
usage () {
echo ".ci/update_remote.sh [option] [target]"
}
push_gitee()
{
git remote add gitee https://SpaceVimBot:${BOTSECRET}@gitee.com/spacevim/SpaceVim.git
git push gitee master
}
push_gitlab()
{
git remote add gitlab https://SpaceVimBot:${BOTSECRET}@gitlab.com/SpaceVim/SpaceVim.git
git push gitlab master
}
push_coding()
{
git remote add coding https://spacevim%40outlook.com:${CODINGBOTSECRET}@e.coding.net/spacevim/SpaceVim.git
git push coding master
}
main () {
case $1 in
--help|-h)
usage
exit 0
;;
gitee)
push_gitee
exit 0
;;
gitlab)
push_gitlab
exit 0
;;
coding)
push_coding
exit 0
;;
esac
}
main $@