Skip to main content
deleted 8 characters in body
Source Link
Ran
  • 7.6k
  • 13
  • 60
  • 72

To remove new files from the staging area (and only in case of a new file), as suggested above:

git removerm --cached FILE

Use removerm --cached only for new files accidentally added.

To remove new files from the staging area (and only in case of a new file), as suggested above:

git remove --cached FILE

Use remove --cached only for new files accidentally added.

To remove new files from the staging area (and only in case of a new file), as suggested above:

git rm --cached FILE

Use rm --cached only for new files accidentally added.

Source Link
Ran
  • 7.6k
  • 13
  • 60
  • 72

To remove new files from the staging area (and only in case of a new file), as suggested above:

git remove --cached FILE

Use remove --cached only for new files accidentally added.