remove file from git already added code example Example: unstage staged files git git reset HEAD file_path