This is probably not a Ubuntu question as such, but a Linux one instead, still hope some Linux user out there can help me understand this.
I'm trying to use the find command to look for some files an a directory tree.
Unfortunately some of the files are named beginning with a dash, like
00n.jpg and so on.
However, every time that the command locates one of the files named that way, it just interrupts the process and complains in the following way:
find: unknown predicate `-001.jpg'
or whatever the file beginning with a dash is named.
It seems to me that somehow the find command is interpreting the resulting filename as an argument, but I haven't found a way to circumvent this behavior.
Thanks in advance for sharing your wisdom.
findcommand itself that is being expanded by the shell into filenames starting with
-(before it is given to
find). Can you edit your question to add the full and exact text of the
findcommand you're issuing, which is producing this problem?