Skip to main content

Notice

Please note that most of the software linked on this forum is likely to be safe to use. If you are unsure, feel free to ask in the relevant topics, or send a private message to an administrator or moderator. To help curb the problems of false positives, or in the event that you do find actual malware, you can contribute through the article linked here.
Topic: how to preserve directory structure of source exactly during conversion (Read 1063 times) previous topic - next topic
0 Members and 1 Guest are viewing this topic.

how to preserve directory structure of source exactly during conversion

Hi I am Rupesh from India and I have lots of mp3 files arranged in various directories and sub directories. I want to convert these into opus files and so I want to converter in foobar.

I want to convert all these files to opus files. I want to maintain target directory which contains directory names same as source and also I want to maintain target filenames same as source. I don't want to organise files according to artists,albums,title etc.,.

From the past two weeks I am trying to achieve above but not succeded so please suggest the string to substitute in destination field of convert option which appears by right click in main window.

Regards,
Rupesh.
Regards,
Rupesh.

 

Re: how to preserve directory structure of source exactly during conversion

Reply #1
You could use syntax $directory(%path%,2)\$directory(%path%,1)\%filename%, which would take two levels deep directory path. For example source file "C:\Music\Heather Nova\(1994) Oyster\02. Heal.mp3" would turn into "Heather Nova\(1994) Oyster\02. Heal". If you need more paths just add extra directory level, like $directory(%path%,3)\$directory(%path%,2)\$directory(%path%,1)\%filename%,. This would use output name "Music\Heather Nova\(1994) Oyster\02. Heal".

Another option is to use syntax $replace(%path%,$left(%path%,3),,.$ext(%path%),). Note that the three letter drive letter removal is only valid for sources with a drive letter, it won't be enough to remove network share name if source is from UNC path.