0

I want to selectivly move all files that are movies with the year at the end of the filename. I have a program that renames movies and fixes the format which always uses Moviename (YEAR).extension format.

I tried mv *(*).* but it just moved everything. I figure the best way would be to do something like move files with brackets and 4 characters in brackets. Also/Or the brackets will always come before the .extension.

1

*'('*')'.* should work.  Better yet, *'('????')'.* should get only the names that have four characters between the parentheses.  Parentheses are special characters, so you have to put them in quotes.

0
 find . -type f -iname "*(*).*" -exec mv  -t ../Final/ {} +
  • That would move the file hello (world). hiya too. – Kusalananda Apr 14 '18 at 7:15
  • Thankfully none of my movies arw formatted in such a way. Which I know 100% – FreeSoftwareServers Apr 14 '18 at 17:05

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.