Assuming that you’ve staged/indexed some files and folders with git add
and want to revert it without loosing your work. Let’s revert it with git reset
command. For more information, click git add and git reset links.
inanzzz@inanzzz:~/project$ git status
On branch develop
Changes to be committed:
(use "git reset HEAD <file>..." to unstage)
deleted: src/AppBundle/AppBundle.php
Changes not staged for commit:
(use "git add <file>..." to update what will be committed)
(use "git checkout -- <file>..." to discard changes in working directory)
modified: app/config/routing.yml
Untracked files:
(use "git add <file>..." to include in what will be committed)
src/Sport/
#git