unable to delete files beginning with `-`
ninedotnine opened this issue · 0 comments
ninedotnine commented
rm
(and various other Unix tools) accept --
as a terminator for arguments,
allowing everything which appears after to be understood as a filename:
» touch -- -Z --xxx
» tree
.
├── --xxx
└── -Z
0 directories, 2 files
» trash -- -Z
» trash -- --xxx
» tree
.
├── --xxx
└── -Z
0 directories, 2 files
» rm -- --xxx
» rm -- -Z
» tree
.
0 directories, 0 files