[bash] sortName not working correctly in command-line argument
Posted: 31 Aug 2018, 00:09
I've been using the Filebot UI to organise all my existing media but am now trying to write a script for automation of renaming / organisation of new media.
I'm using Debian Linux with Filebot in a docker (rednoah/filebot) for context.
The script runs perfectly aside from sortName functionality which is dropping the name of the TV series completely just leaving punctuation marks at the series folder level.
If I use {n.sortName} for example on the TV Show The Wire, it will return - Wire/Season 01/... - if I then adjust it to {n.sortName('$2, $1') it will return - , /Season 01/... -
Have been scouring the forums for a solution or someone with a similar issue but have had no luck. Understand that there is an issue with $ symbol on Linux from previous posts.
Have tried this format from another post which returns the same.
I'm using Debian Linux with Filebot in a docker (rednoah/filebot) for context.
The script runs perfectly aside from sortName functionality which is dropping the name of the TV series completely just leaving punctuation marks at the series folder level.
If I use {n.sortName} for example on the TV Show The Wire, it will return - Wire/Season 01/... - if I then adjust it to {n.sortName('$2, $1') it will return - , /Season 01/... -
Have been scouring the forums for a solution or someone with a similar issue but have had no luck. Understand that there is an issue with $ symbol on Linux from previous posts.
Have tried this format from another post which returns the same.
Code: Select all
seriesFormat="{n.replaceFirst(/^(?i)(The|A)\s(.+))/, /$2, $1/)}"