Files
git-repo-sync/entrypoint.sh
T
Wang Chucheng 63782025e8
build / Git Repo Sync (push) Failing after 4s
feat: add basic sync
2021-04-10 14:56:30 +08:00

14 lines
332 B
Bash
Executable File

git remote add target https://${INPUT_TARGET_USERNAME}:${INPUT_TARGET_TOKEN}@${INPUT_TARGET_URL#https://}
case "${GITHUB_EVENT_NAME}" in
push)
git push -f --all target
git push -f --tags target
;;
delete)
git push -d target ${GITHUB_EVENT_REF}
;;
*)
break
;;
esac