- You have created a new git repository in your current directory with the ‘git init’ command.
Further, you have edited and saved a new file name ‘README’ to the current directory.
What sequence of commands will permanently save the new file ‘README’ to your repository?
a) git status; git add README; git diff —staged; git commit -m “created README”
b) git status; git commit -m “created README”; git status; git log
c) git add README; git diff —staged; git commit; git status
d) git status; git add README; git status; git diff —staged; git log
- Files under git control go through three main stages: working files, staging area, and repository.
Draw a picture that illustrates the relationship between these three stages and the following git commands:
git add
git checkout
git commit