DEV Community

Discussion on: Deleting files that start with a hyphen in Bash

Collapse
 
_morgan_adams_ profile image
morgana

Nice one!

I'm going to work that into my post and credit you with that one if that's okay.

I knew you could use ls to see inode info, but I didn't know you could use inode info with find.

Collapse
 
makhauser profile image
mkh

Sure you can, but that is an old instruction, don't even remember where I have found it. Most likely on the Cybercity. What is good in this trick - you can delete the file with any naming issues either it has slashes, dashes or whatever.