Created
May 22, 2020 13:57
-
-
Save evan-moon/e0481a718b545d79e4e41e94c09f1651 to your computer and use it in GitHub Desktop.
비트버킷 -> 깃허브 레포 마이그레이션 쉘 스크립트
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
echo '========== Welcome to Bitbucket -> Github migration!!! ==========' | |
echo 'Please insert github repository URL ->' | |
read -p '[URL] : ' githubURL | |
echo 'Checkout to master branch...' | |
git reset --hard HEAD | |
git co master | |
git pull | |
echo 'Start migration...' | |
git remote rename origin bitbucket | |
git remote add origin $githubURL | |
git push origin master | |
echo 'Finish migration' |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment