github add existing project to new repo code example
Example 1: git add existing project to repository
git remote add origin <repository url>
git branch -M main
git push -u origin main
Example 2: push a project to an existing repoin github using git
$ git init -b main