What is the difference between:
git clean -f temp1.txt
and
rm temp1.txt
Git doc says:
git-clean
- Remove untracked files from the working tree
So what is really the point of doing this instead of only the system command?
rm
will delete the file no matter what. git-clean
will only delete it if it's actually untracked. And of course git-clean
also accepts arguments that customize its behavior in a repo-aware manner (e.g. -x
).
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With