Skip to content

Instantly share code, notes, and snippets.

@jadia
Last active February 1, 2019 05:05
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save jadia/71d65ce241d5956593bb542ae6992b5a to your computer and use it in GitHub Desktop.
Save jadia/71d65ce241d5956593bb542ae6992b5a to your computer and use it in GitHub Desktop.
Git commit all deleted files

Git commit all deleted files

git add -u

man from git-add

-u, --update

Only match <filepattern> against already tracked files in the index rather than the working tree. That means that it will
never stage new files, but that it will stage modified new contents of tracked files and that it will remove files from the
index if the corresponding files in the working tree have been removed.

If no <filepattern> is given, default to "."; in other words, update all tracked files in the current directory and its subdirectories.

source

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment