cd existing_repo
git init
git remote add origin https://gitlab.com/your_account_name/project_name.git
git branch -M main
git add .
git commit -m "Initial commit"
git push -uf origin main
git init
git add .
git commit -m "Push existing project to GitLab"
git remote add source https://gitlab.com/cameronmcnz/example-website.git
git push -u -f source master
## Git push using SSH
git push --set-upstream git@gitlab.example.com:namespace/nonexistent-project.git master
## Git push using HTTPS
git push --set-upstream https://gitlab.example.com/namespace/nonexistent-project.git master
git push --set-upstream git@gitlab.example.com:namespace/myproject.git master