I have a filename with -v. I try to remove it by
-v
rm -v or rm "-v" or rm ¥-v
But it shows something like
rm: missing operand Try 'rm --help' for more information.
I have a filename with -v
Try:
rm -- '-v'
If you need to use rm option like verbose for example, try:
rm
rm -v -- '-v'
-- tells SHELL it's the end of options. And disables further option processing. So anything after -- will be treated as filenames.
--
Try:
If you need to use
rmoption like verbose for example, try:--tells SHELL it's the end of options. And disables further option processing. So anything after--will be treated as filenames.