Want to move a repo from GitLab to GitHub and keep all commits, branches, and tags? Here’s a super simple way 👇

#!/bin/bash

# Replace these with your info
GITLAB_REPO="https://gitlab.com/yourname/your-repo.git"
GITHUB_REPO="https://github.com/yourname/your-repo.git"

# Clone from GitLab
git clone --mirror "$GITLAB_REPO"
cd your-repo.git

# Push to GitHub (with all history + branches + tags)
git remote set-url origin "$GITHUB_REPO"
git push --mirror

# Done!
echo "✅ Repo migrated from GitLab to GitHub!"