Skip to content

Instantly share code, notes, and snippets.

@evan-moon
Created May 22, 2020 13:57
Show Gist options
  • Save evan-moon/e0481a718b545d79e4e41e94c09f1651 to your computer and use it in GitHub Desktop.
Save evan-moon/e0481a718b545d79e4e41e94c09f1651 to your computer and use it in GitHub Desktop.
비트버킷 -> 깃허브 레포 마이그레이션 쉘 스크립트
#!/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