push a single file in git

C++
$ git commit -m "Message goes here" filename

Source

Also in C++: