Rename Command Allows Regex Like Sed (well, actually Perl)

Rename Command Allows Regex Like Sed (well, actually Perl)

eg. for filenames like test.zip?abc=123" turn them into just test.zip
rename 's/\?.+//' -- * where 's/\?.+//' is a Perl expression!

Leave a Reply

Your email address will not be published. Required fields are marked *