[AMC] Custom File Struture for Audio files

Running FileBot from the console, Groovy / FileBot scripting, shell scripts, etc
Post Reply
gplans
Posts: 5
Joined: 26 Mar 2013, 17:12

[AMC] Custom File Struture for Audio files

Post by gplans »

I have just setup Filebot on my Synology NAS.

I have automated it so that every night it will change the names of the files I place in a particular directory. It them renames them and puts the movies in the movie forder etc.

What I want to do is make the audiobooks go into a audiobook folder not the music folder. All the audiobooks have the extension .m4b.

Can this be done?

Thanks
User avatar
rednoah
The Source
Posts: 20160
Joined: 16 Nov 2011, 08:59

Re: Synology Node File Struture

Post by rednoah »

Yes, but I'm not sure if FileBot Node (i.e. amc script) is the way to go. Perhaps a custom --def musicFormat will do if things are already working and you just want to customize the destination file structure.

In general, Plain File Mode might be more suitable for processing audio files and generating file paths based MediaInfo properties.
:idea: Please read the FAQ and How to Request Help.
gplans
Posts: 5
Joined: 26 Mar 2013, 17:12

Re: [AMC] Custom File Struture for Audio files

Post by gplans »

Maybe I am not that technical. I was hoping for a straightforward solution for making my filebot node on my Synology to send audiobooks into a audiobook folder and music into the music folder automatically every night.
User avatar
rednoah
The Source
Posts: 20160
Joined: 16 Nov 2011, 08:59

Re: [AMC] Custom File Struture for Audio files

Post by rednoah »

gplans wrote: 28 Sep 2021, 22:26 I was hoping for a straightforward solution for making my filebot node on my Synology to send audiobooks into a audiobook folder and music into the music folder automatically every night.
That would require a custom music format that generates audiobook file paths for some audio files and music file paths for other audio files. Notably, you'd need to express in code how to tell apart audiobook files and music files.


:idea: The default music format is the {plex} format which generates files paths akin to this:

Code: Select all

Music/{n}/{album+'/'}{pi.pad(2)+'. '}{artist} - {t}

:idea: If we were to assume that audio files longer than 20 minutes are audio books, and not music tracks, and then just switch out the Music folder name in that case, then things will get very straightforward:

Code: Select all

{ minutes >= 20 ? 'AudioBooks' : 'Music' }/{n}/{album+'/'}{pi.pad(2)+'. '}{artist} - {t}
:idea: Please read the FAQ and How to Request Help.
Post Reply