An attempt to delete all files from the repository ends with an error:
$ git rm -r * error: the following files have been changed in the index:
How to understand this error? What should I do to remove?
An attempt to delete all files from the repository ends with an error:
$ git rm -r * error: the following files have been changed in the index:
How to understand this error? What should I do to remove?
Pre-notification : I don’t consider the question of the meaningfulness of the action itself to delete all files from the repository: what if it really does.
The full text of the message is:
error: the following file has been changed in the index:
list of files
(use --cached to keep the file, or -f to force removal)
if your task is to really delete files, then use the second hint by adding the -f option
$ git rm -rf * after this, of course, it will be necessary to fix these changes in the repository using the commit command:
$ git commit there is a similar error due to the fact that with the help of the add command you added some changes to the index (a new file or changes already being monitored), but did not fix them with commit .
Source: https://ru.stackoverflow.com/questions/543611/
All Articles
git config --global user.email "you@example.com"- lexxl