Making Commits in Git
After we have indexed the files, we can commit. The commit saves the current state of the project. At the same time, we must add a comment to each commit about the essence of the changes made.
Commits are made using the commit command. In this case, after the -m flag, we must write a commit comment in quotes. So, let's make our commit:
git commit -m "my first commit"
If you want, if the comment is large, you can type it in a text editor. To do this, do not write the -m flag and simply execute the commit command. After executing this command, the text editor you linked will open and you will be able to write a comment to the commit in it:
git commit
Commit your indexed files. Check the status.
Make changes to your files. Check the status. Stage the changes. Check the status. Commit. Check the status.