I've been using git for a couple of years and after adding a file using "git add" we can unstage it using command "git reset HEAD file1 file2
".
This command is even specified when we try to commit changes:
(use "git reset HEAD ..." to unstage)
To my understanding it only unstages the specified files and do nothing else.
Today I gave this command
git reset HEAD a.php test.php #to unstage some left over test files
after running it it generated lot of warnings like
M public/www.mysite.com/public/sites/all/modules/unique_field/unique_field.module
M public/www.mysite.com/public/sites/all/modules/variable/variable.module
M public/www.mysite.com/public/sites/all/modules/variable/variable_admin/variable_admin.module
M public/www.mysite.com/public/sites/all/modules/variable/variable_example/variable_example.module
M public/www.mysite.com/public/sites/all/modules/variable/variable_realm/variable_realm.module
M public/www.mysite.com/public/sites/all/modules/variable/variable_store/variable_store.module
M public/www.mysite.com/public/sites/all/modules/variable/variable_views/variable_views.module
M public/www.mysite.com/public/sites/all/modules/views/tests/views_test.module
M public/www.mysite.com/public/sites/all/modules/views/views.module
This answer confirms what I understand Does `git reset HEAD file` also check out the file? but why it always show lot of warnings which seem to be that those "M"
files have been modified.
Can anyone explain me this threatening what "M
" means and why it should be even listing such warnings?