0 votes
in Technology by (438k points)

How will you remove a file from Git without actually removing it from your local filesystem?

1 Answer

0 votes
by (438k points)

You can use the ‘cached’ option for this:

git rm -rf –cached $FILES

This command will remove the files from your repository without deleting them from your disk.

...