(note the extra a in the flags, can also be written as git commit -a -m "message" - both do the same thing)

Alternatively, if you want to be more selective about what you add to the commit, you use the git add command to add the appropriate files to the staging area, and git status to preview what is about to be added (remembering to pay attention to the wording used).

You can also find general documentation and tutorials for how to use git on the git documentation page which will give more detail about the concept of staging/adding files.

One other thing worth knowing about is interactive staging - this allows you to add parts of a file to the staging area, so if you've made three distinct code changes (for related but different functionality), you can use interactive mode to split the changes and add/commit each part in turn. Having smaller specific commits like this can be helpful.