how to remove a file added to git code example Example: how to unadd gitr file git reset HEAD myfile.txt