git init
# Optional: create branch
git checkout -b branch_name
git add .
git commit -m "Adds existing project to GitHub remote repository"
git remote add origin https://github.com/username/example-project.git
git pull --rebase origin main
# Resolve merge conflicts if needed
git push origin main
# push any desired branch to remote
git push -u origin local_branch_name:remote_branch_name
git checkout -b my_new_branch
git commit