Copy files conditionally based on path,folderdepth

Post any Bulk Rename Utility support requirements here. Open to all registered users.

Copy files conditionally based on path,folderdepth

Postby ginjaninja » Mon Dec 23, 2013 4:56 pm

Hi BRU Support

I am testing out a new media server which has a different convention for fanart, so i need to copy my fanart from the mediaserver1s conventions over to mediaserver2's conventions (so both show fanart during the test).
specifically
Current/MediaServer1 convention
T:\TV1\Showname\
T:\TV1\Showname\Folder.jpg (fanart for show)
T:\TV2\Showname\Season XX (where XX is a season number 00,01,02,03 etc)
T:\TV2\Showname\Season XX\folder.jpg (fanart for season)

MediaServer2 Convention is
T:\TV1\Showname\
T:\TV1\Showname\show.jpg (fanart for show)
T:\TV2\Showname\Season XX (where XX is a season number 00,01,02,03 etc)
T:\TV2\Showname\Season XX\Season-XX.jpg (fanart for season)

Could anyone advise me on how to copy the show and season fanart to the new convention

Ideas for Show fanart - might some logic around this be possible?
Copy all folder.jpg (which are two subfolders deep) as show.jpg

Ideas for Season Fanart
Copy all folder.jpg (which are three subfolders deep) as season-XX.jpg where XX is derived somehow from the parent folder.

Could anyone advise please. I have c. 2000 to copy and it would be a big manual task.
thank you
ginjaninja
 
Posts: 2
Joined: Mon Dec 23, 2013 4:33 pm

Re: Copy files conditionally based on path,folderdepth

Postby ginjaninja » Mon Dec 23, 2013 9:47 pm

https://dl.dropboxusercontent.com/u/84611964/BRU.rar

found a brute force solution, theres probably a more succint way.
1. Copy all folder.jpgs to a new strucutre to be processed using robocopy
2. Run 3 BRU commands to procecss
a) append the parent folder to the filename (all fanart in season folders will have season XX appended, series fanart wont)
b) use a filter to filterout all season images and change remainder to show.jpg
c) use a filter to filterin only seasonimages and rename appropriately.
3. copy processed structure back over original to added in the new filenames.
when i have time i will work out a BRC script that can do it on the fly so that the 2 mediasystems paradigms will be maintained in relatime (or at least on a schedule)
ginjaninja
 
Posts: 2
Joined: Mon Dec 23, 2013 4:33 pm


Return to BRU Support