git remove added file before commit

C++
git reset <file> or git resetgit reset file-namegit resetgit reset HEAD myfile.txt
git reset

Source

Also in C++: