Sorting Folder movies by Subtitile or not

All about user-defined episode / movie / file name format expressions
Post Reply
neriox
Posts: 18
Joined: 04 Feb 2013, 02:14

Sorting Folder movies by Subtitile or not

Post by neriox »

hello, I'm trying to mount one final scheme, which can separate my movies at 2 big folders: one folder with the movies they already own subtitle ( External srt files, without being included in the MKV or embedded) and a folder with movies without caption.
I'm trying to use the function:
folder.list().find
but I'm not getting results. Using the text function, which only works on MKV and other packages (and does not work in avi, which I also use), I can not, because many come with subitiles but text caption in English, and I would like to share based on criteria external subtitle and Portuguese.
At the moment this is my pattern:

Code: Select all

\{n} [{y}]{"[$vf]"}{"[$rating]"}{"$genres"}\{fn}{".$lang"}
Is there some other way?

Example:

Code: Select all

Movie1.avi
Movie1.pob.srt  
Movie2.mkv
After:

Code: Select all

Folder Movies\
------------------\With Subtitle\Movie1 [2014] [Action,Drama]\Movie1.avi
------------------\With Subtitle\Movie1 [2014] [Action,Drama]\Movie1.pob.srt
------------------\Without Subtitle\Movie2 [2013] [Action,Comedy]\Movie1.mkv
User avatar
rednoah
The Source
Posts: 22923
Joined: 16 Nov 2011, 08:59
Location: Taipei
Contact:

Re: Sorting Folder movies by Subtitile or not

Post by rednoah »

Like this:

Code: Select all

{folder.listFiles().any{ it =~ /[.]srt/ } ? '/With Subtitles' : '/Without Subtitles'}
:idea: Please read the FAQ and How to Request Help.
Post Reply