How do you use git to bulk perform rm operations on files

134 4

With a long time git, there's a problem with it. As some modifications are made, it's generally"git add."the file is staged.

But"git add."isn't valid for deleted content, and the"git rm filename"is required to delete the file, but the git rm command doesn't seem like"git rm.". I'm basically almost all to the gui git ( for example, the tower of mac ). The batch stage is done, but the command line is more convenient below. It's more convenient to write a script.

5 Answers

79 2
git add -A

It sends us all the stage we didn't remove from git rm.

139 1

Another git commit -a can be used, roughly deleted files, but no new files are available for the new file.
-a, --all ____ tell the command to automatically stage files that have been modified and _ new files you not told about.