Created
January 8, 2019 02:57
-
-
Save castaneai/626099e13a497c2e727ad17440ec2f9f to your computer and use it in GitHub Desktop.
Migrating private repo to GitHub from GitLab.
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 | |
GITLAB_USER=castaneai | |
GITHUB_USER=castaneai | |
REPO_NAME=$1 | |
git clone --mirror https://gitlab.com/$GITLAB_USER/$REPO_NAME && cd $REPO_NAME.git && hub create -p $REPO_NAME && git remote set-url origin https://github.com/$GITHUB_USER/$REPO_NAME.git && git push --mirror |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment