When you decide to use a version control system (VCS) into your project using git And start creating the project
folder and writing the first commands,
$ git init
Now we need to add our file into the Repository
$ git add test_code.js
Now the test_code.js file in the Staging area ( Index )
$ git status
The last step we need to run
$ git committo captures a snapshot of the project's currently staged changes.
$ git commit
Then the default text editor will run you need to write i letter to start typing the commit message and once you have done you need to click on esc button and input :wq to save and quite ,
Here's the problem if you didn’t familiar with the default Vim or nano text editor you need to add this command to use your favourite text editor,
$ git config --global core.editor "Atom"
i'll use Atom as a text editor.
finally Run this command
git commit --amendto recover the commit message by input R then press Enter and run the
$ git commitagain
Good Luck and Happy Learning