todo-list
or ng-girls-todo-list
.git
(you can click the "copy" button on the right side to copy all the commands) and paste into the terminal that's open in your project folder. (You don't have to paste line by line. You can copy all three lines and paste them. The commands will run one after the other, except the last one where you'll have to hit Enter.)git remote add origin...
connects the project to the GitHub repository you have created. It configures the remote location of the project, so that each time you sync the code (push changes to the remote or pull from it) you don't need to specify the remote explicitly.git branch -M main
renames the default branch from master
to main
, since it has become the new standard to name it. git push -u origin main
pushes the code from the main branch to the GitHub repository using the configuration of the origin
as you have set in the first command. .
represents the current location. Alternatively, you can specify a file.)git add --all
or git add -A
. git checkout -b new-branch-name
- create a new branch and switch to it
git checkout main
- switch back to the main branch (use git checkout
to switch to any existing branch)
After committing your changes in the branch, you can push them to GitHub and create a Pull Request. There you'll be able to review the changes, discuss them, comment directly on the code snippets, push additional changes, and finally approve the pull request and merge it to main. Then, sync your local main branch by running git pull
.