- go to old_name branch: $ git branch -m new_name
- or outside that branch: $ git branch -m old_name new_name
- $ git push origin :old_name new_name
- $ git branch -d branch_name
- $ git push origin --delete branch_name
- $ git init
- $ git remote add origin (REPO_LINK)
- $ git config --global user.email "you@example.com"
- $ git push --set-upstream origin main // continue even if you get an error
- $ git add .
- $ git commit -m "message"
- $ git branch new_branch_name
- $ git checkout new_branch_name
- $ git add .
- $ git commit -m "real message"
- $ git push
- $ git checkout new_branch
- $ git checkout main . // With period
- $ git add --all
- $ git commit -m "Copy from main to new_branch"
- $ git push -u origin new_branch
- $ git remote remove origin
- $ git remote add origin (NEW REPO LINK)
- $ git push --set-upstream origin (branch_name)
- $ git reset --hard origin/develop
- $ git checkout -b (local_branch_name) origin/(remote_branch_name) // creates it
- $ git pull origin (remote_branch_name) // if it didn't pull automatically from the previous step