Created
November 15, 2021 22:09
-
-
Save swanandmehta/865ad6a4b474275c3322e21b02e1f9bc to your computer and use it in GitHub Desktop.
Migration from GIT to GIT
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
#!/usr/bin/env sh | |
echo Please provide git project old repo : | |
read oldRepo | |
echo Please provide git project new repo : | |
read newRepo | |
echo Please provide git project name : | |
read projectName | |
root="${projectName}_root" | |
mkdir -p $root | |
cd $root | |
git clone --mirror $oldRepo | |
cd $projectName | |
git push --mirror $newRepo | |
read -p "Press [Enter] key to quit the program." |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment