while working with git repos, sometins we need to update files those are not tracked by git. so if you want to remove all those files then run the following command.
Running this command can delete all untracked fiels like, node_modules and any project specific files. be cautious while running this command
Git Remove all untracked files
//just show what would be removed. does not delete anything
git clean -n
// will delete files and folders
git clean -fd
Flags:
- f: force
- d: directory