Automatically add the language (e.g. "ENG" or "DE") to srt files?

Support for Windows users
Post Reply
Biff
Posts: 241
Joined: 02 Mar 2014, 17:52

Automatically add the language (e.g. "ENG" or "DE") to srt files?

Post by Biff »

Can FileBot automatically add the language (e.g. "ENG" or "DE") to srt files when renaming them (sometimes it does sometimes it does not)?
Image

And the same for forced subs:
Image
becomes:
Image
Newest portable, stable FileBot, Windows 10 Home, 64bit
User avatar
rednoah
The Source
Posts: 22999
Joined: 16 Nov 2011, 08:59
Location: Taipei
Contact:

Re: Automatically add the language (e.g. "ENG" or "DE") to srt files?

Post by rednoah »

Yes, that's what {subt} and {lang} are for. The {plex} binding will also take care of the subtitle tag implicitly.

What format are you using?
:idea: Please read the FAQ and How to Request Help.
Biff
Posts: 241
Joined: 02 Mar 2014, 17:52

Re: Automatically add the language (e.g. "ENG" or "DE") to srt files?

Post by Biff »

Thank you, rednoah.

Strange, {subt} and {plex} are not implemented. Where do I have to add them? And although I have {lang} added sometimes it does not work.

I use this format:
I:\Eigene Dateien\Videos\Filme\{n.replace(':', ' -')} ({y}){' CD'+pi}{'.'+lang}{tags}{file.path =~ /Kinofassung/ ? '[Theatrical Cut]' : ''}

Many thanks again
Newest portable, stable FileBot, Windows 10 Home, 64bit
User avatar
rednoah
The Source
Posts: 22999
Joined: 16 Nov 2011, 08:59
Location: Taipei
Contact:

Re: Automatically add the language (e.g. "ENG" or "DE") to srt files?

Post by rednoah »

1.
Are you using the latest version of FileBot?

2.
Are you testing with real text-based subtitle files? If you use image-based subtitle files (e.g. idx/sub) or empty files then statistical language detection may not work.
:idea: Please read the FAQ and How to Request Help.
Biff
Posts: 241
Joined: 02 Mar 2014, 17:52

Re: Automatically add the language (e.g. "ENG" or "DE") to srt files?

Post by Biff »

1. Yes, I do, the portable one.

2. Yes, I use the original srt files, no dummies, empty files or such.
If you use image-based subtitle files (e.g. idx/sub)
I do not know what image-based file are, but, yes, such files I have also and idx files.
Newest portable, stable FileBot, Windows 10 Home, 64bit
User avatar
rednoah
The Source
Posts: 22999
Joined: 16 Nov 2011, 08:59
Location: Taipei
Contact:

Re: Automatically add the language (e.g. "ENG" or "DE") to srt files?

Post by rednoah »

1.
Biff wrote:1. Yes, I do, the portable one.
What's the sysinfo output?
Biff wrote:{subt} and {plex} are not implemented.
This indicates that you're using an older version.


2.
Language detection won't work for idx/sub files, unless you add language tags like ".eng" to the filename yourself first. You won't have such issues with *.srt or *.ass subtitle files.
:idea: Please read the FAQ and How to Request Help.
Biff
Posts: 241
Joined: 02 Mar 2014, 17:52

Re: Automatically add the language (e.g. "ENG" or "DE") to srt files?

Post by Biff »

1.
Sorry, how can I get that output? It is 4.7.2:
Image
This indicates that you're using an older version.
Sorry again, I meant not implemented in my formats, it is available:
Image

2.
Alright, so I would have to add the language tags manually to idx/sub files.
Newest portable, stable FileBot, Windows 10 Home, 64bit
User avatar
rednoah
The Source
Posts: 22999
Joined: 16 Nov 2011, 08:59
Location: Taipei
Contact:

Re: Automatically add the language (e.g. "ENG" or "DE") to srt files?

Post by rednoah »

1.
If you want to test these bindings, you need to select a sample file.

"plex" => NO
"C:/path/to/subtitles.eng.srt" => YES

Click on the "Open Folder" icon and select a subtitle file you want to test with.
:idea: Please read the FAQ and How to Request Help.
Biff
Posts: 241
Joined: 02 Mar 2014, 17:52

Re: Automatically add the language (e.g. "ENG" or "DE") to srt files?

Post by Biff »

"plex" => NO
"C:/path/to/subtitles.eng.srt" => YES
Very sorry, I cannot understand.
Newest portable, stable FileBot, Windows 10 Home, 64bit
User avatar
rednoah
The Source
Posts: 22999
Joined: 16 Nov 2011, 08:59
Location: Taipei
Contact:

Re: Automatically add the language (e.g. "ENG" or "DE") to srt files?

Post by rednoah »

rednoah wrote:Click on the "Open Folder" icon and select a subtitle file you want to test with.
The "Media File" input field expects you to enter a valid file path. "plex" is not a valid file path.
:idea: Please read the FAQ and How to Request Help.
Biff
Posts: 241
Joined: 02 Mar 2014, 17:52

Re: Automatically add the language (e.g. "ENG" or "DE") to srt files?

Post by Biff »

Sorry again, where do I have to add {subt} and {plex} to my format?

Code: Select all

I:\Eigene Dateien\Videos\Filme\{n.replace(':', ' -')} ({y}){' CD'+pi}{'.'+lang}{tags}{file.path =~ /Kinofassung/ ? '[Theatrical Cut]' : ''}
Newest portable, stable FileBot, Windows 10 Home, 64bit
User avatar
rednoah
The Source
Posts: 22999
Joined: 16 Nov 2011, 08:59
Location: Taipei
Contact:

Re: Automatically add the language (e.g. "ENG" or "DE") to srt files?

Post by rednoah »

Wherever you want. Most people would put it at the end.

e.g. 1st built-in example movie format:

Code: Select all

{n.colon(' - ')} ({y}){' CD'+pi}{subt}
:idea: Please read the FAQ and How to Request Help.
Biff
Posts: 241
Joined: 02 Mar 2014, 17:52

Re: Automatically add the language (e.g. "ENG" or "DE") to srt files?

Post by Biff »

So, this could be right:
I:\Eigene Dateien\Videos\Filme\{n.replace(':', ' -')} ({y}){' CD'+pi}{'.'+lang}{tags}{file.path =~ /Kinofassung/ ? '[Theatrical Cut]' : ''}{n.colon(' - ')} ({y}){' CD'+pi}{subt}
?

And where can I add {plex}?
Newest portable, stable FileBot, Windows 10 Home, 64bit
User avatar
rednoah
The Source
Posts: 22999
Joined: 16 Nov 2011, 08:59
Location: Taipei
Contact:

Re: Automatically add the language (e.g. "ENG" or "DE") to srt files?

Post by rednoah »

At this point you can either pay me for my services, or figure it out for yourself. I most highly recommend the latter. ;)
:idea: Please read the FAQ and How to Request Help.
Biff
Posts: 241
Joined: 02 Mar 2014, 17:52

Re: Automatically add the language (e.g. "ENG" or "DE") to srt files?

Post by Biff »

Ah yes, thank you, that's a great and cool idea, how much do you want? May be I could also pay some money for using this nice website and or the traffic I am generating posting here. Hope, it will not be that much.
Newest portable, stable FileBot, Windows 10 Home, 64bit
User avatar
rednoah
The Source
Posts: 22999
Joined: 16 Nov 2011, 08:59
Location: Taipei
Contact:

Re: Automatically add the language (e.g. "ENG" or "DE") to srt files?

Post by rednoah »

Your format already looks good to me. I see no reason why you'd want to use the {plex} binding if you already have your customized format.
:idea: Please read the FAQ and How to Request Help.
Biff
Posts: 241
Joined: 02 Mar 2014, 17:52

Re: Automatically add the language (e.g. "ENG" or "DE") to srt files?

Post by Biff »

With this format
I:\Eigene Dateien\Videos\Filme\{n.replace(':', ' -')} ({y}){' CD'+pi}{'.'+lang}{tags}{file.path =~ /Kinofassung/ ? '[Theatrical Cut]' : ''}{n.colon(' - ')} ({y}){' CD'+pi}{subt}
Filebot does this:
Image

There must be anything wrong with the format.
Newest portable, stable FileBot, Windows 10 Home, 64bit
Post Reply