When migrating repositories from GitLab, they fall into two categories:
-
Repositories created under a group space (e.g. https://git.dartmouth.edu/GROUP/repo)
-
Repositories created under your personal space (e.g. https://git.dartmouth.edu/NETID/repo)
1. Migrating repositories from a group space
2. Migrating repositories from your personal space
- If you only want to clone the repositories locally on your machine, you can ignore the next step in this guide
- Create an account with an alternative Git service (e.g. github.com, gitlab.com, etc.)
- Complete the following steps
- Clone the repository locally
- Create a new repository on the destination platform
- Update repository configuration
- Push to the new repository
- Verify migration and update places where you've been using this repository
- Here are the example commands you can follow to accomplish these steps
git clone <your-git-repo-uri>
cd your-repo
# Create the repository in the new location using the Service Website
git remote rename origin old-origin
git remote add origin <your-new-git-remote-repo-uri>
git push
--set-upstream origin --all
git push
--set-upstream origin --tags