Answer the question
In order to leave comments, you need to log in
How to escape characters in rename?
I want to remove part of the filename -2.7.27-3324
using the rename utility. You need to remove part of the filename in all directories starting from the source directory. I'm trying to do this:
I get an error:
rename -f -n 'y/-8.3.18-1334//' *.png
Invalid range "8-1" in transliteration operator at (user-supplied code).
\
and '
. Does not help. Tell me how to correctly specify the options for rename?
Answer the question
In order to leave comments, you need to log in
find. -name *.png -type f -exec rename -f 's/-2\.7\.27-3324//' '{}' \;
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question