You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: README.md
+23-10Lines changed: 23 additions & 10 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -213,7 +213,7 @@ All language conditions with positive scores *and* Negated conditions with negat
213
213
The script also supports command-line arguments that will override the automatic language detection. More granular control can therefore be exerted or extended using tagging and defining multiple *Connect* scripts (this is native Radarr/Sonarr functionality outside the scope of this documentation).
`-a`, `--audio`|`<audio_languages[+modifier]>`|Audio languages to keep<br/>ISO 639-2 code(s) prefixed with a colon (`:`)<br/>Each code may optionally be followed by a plus (`+`) and one or more [modifiers](#language-code-modifiers).
225
225
`-s`, `--subs`|`<subtitle_languages[+modifier]>`|Subtitle languages to keep<br/>ISO 639-2 code(s) prefixed with a colon (`:`)<br/>Each code may optionally be followed by a plus (`+`) and one or more modifiers.
226
226
`-f`, `--file`|`<video_file>`|If included, the script enters **[Batch Mode](#batch-mode)** and converts the specified video file.<br/>Requires the `--audio` option.<br/>![notes] **Do not** use this argument when called from Radarr or Sonarr!
227
-
`--reorder`||Reorder audio and subtitles tracks to match the language code order specified in the `<audio_languages>` and `<subtitle_languages>` arguments.
228
-
`--disable-recycle`||Disable recycle bin use, even if configured in Radarr/Sonarr
227
+
`--reorder`||Reorder audio and subtitles tracks to match the language code order specified in the `<audio_languages>` and `<subtitle_languages>` arguments.
228
+
`--disable-recycle`||Disable recycle bin use, even if configured in Radarr/Sonarr
229
229
`--skip-profile`|`<profile_name>`|Skip processing if the video was downloaded using the specified Quality Profile name. May be specified multiple times to skip multiple profiles.
230
-
`--set-default-audio`|`<language_code[=name]>`|Set the default audio track to the first track of the specified language. Only one language code is allowed. If specified, all other tracks are marked as not default.<br/>The code may optionally be followed by an equals (`=`) and a [track name](#setting-default-track) matching string.
231
-
`--set-default-subs`|`<language_code[=name]>`|Set the default subtitles track to the first track of the specified language. Only one language code is allowed. If specified, all other tracks are marked as not default.<br/>The code may optionally be followed by an equals (`=`) and a track name string.
230
+
`--set-default-audio`|`<language_code[=name][-f]>`|Set the default audio track to the first track of the specified language. Only one language code is allowed. If specified, all other tracks are marked as not default.<br/>The code may optionally be followed by an equals (`=`) and a [track name](#setting-default-track) matching string.<br/>The code may optionally be followed by a minus f (`-f`) to indicate skipping Forced tracks.
231
+
`--set-default-subs`|`<language_code[=name][-f]>`|Set the default subtitles track to the first track of the specified language. Only one language code is allowed. If specified, all other tracks are marked as not default.<br/>The code may optionally be followed by an equals (`=`) and a track name string.<br/>The code may optionally be followed by a minus f (`-f`) to indicate skipping Forced tracks.
232
232
`-l`, `--log`|`<log_file>`|The log filename<br/>Default is `/config/log/striptracks.txt`
233
233
`-c`, `--config`|`<config_file>`|Radarr/Sonarr XML configuration file<br/>Default is `/config/config.xml`
234
234
`-p`, `--priority`|`idle`, `low`, `medium`, `high`|CPU and I/O process priority for mkvmerge<br/>Default is `medium`<br/>![notes] High priority can consume all system resources. When processing a large video file your system may become unresponsive!
235
235
`-d`, `--debug`|`[<level>]`|Enables debug logging. Level is optional.<br/>Default is `1` (low)<br/>`2` includes JSON output<br/>`3` contains even more JSON output
236
-
`--help`||Display help and exit.
237
-
`--version`||Display version and exit.
236
+
`--help`||Display help and exit.
237
+
`--version`||Display version and exit.
238
238
239
239
</details>
240
240
@@ -281,8 +281,12 @@ Modifiers may be combined, such as `:any+fd` to keep all forced and all default
281
281
Use the `--set-default` options to choose tracks that appear first when the video is played. Only one audio and one subtitles track may be set as default. The language code is the same colon (`:`) prepended ISO 639-2 language code used with the `--audio` and `--subs` options.
282
282
The first track of the specified language will have its default flag set and all other tracks (of any language) will have their default flag disabled.
283
283
284
-
The language code can optionally be followed by an equals (`=`) and a string which is used to match against the track name. The first track that matches the specified language and with a name that matches the string will be set to default.
285
-
The string matching uses a substring and is case insensitive. You can use this to set the default subtitles track to hearing impared (SDH), or the audio track to your preferred language.
284
+
The language code can optionally be followed by an equals (`=`) and a string which is matched against the track name. The first track that matches the specified language and with a name that matches the string will be set to default.
285
+
The string matching uses a substring and is case insensitive. You could use this to set the default subtitles track to hearing impared (SDH), for example.
286
+
287
+
The language code can optionally be followed by a minus f (`-f`) which indicates skipping tracks that have the forced flag set when choosing the default track.
288
+
289
+
The order of the `=name` and `-f` modifiers is not important.
286
290
287
291
The setting of default track flags occurs after the track selection logic.
288
292
@@ -291,14 +295,17 @@ The setting of default track flags occurs after the track selection logic.
291
295
> You may therefore not obtain consistent results.
292
296
293
297
<details>
294
-
<summary>Track Name Examples</summary>
298
+
<summary>Default Track Examples</summary>
295
299
296
300
If you want to set the default subtitles track to the first hearing impared English track, you would use:
297
301
`--set-default-subs :eng=SDH`
298
302
299
303
To set the default audio track to Dutch:
300
304
`--set-default-audio :dut`
301
305
306
+
To set the default subtitles track to the first non-forced English track:
307
+
`--set-default-subs :eng-f`
308
+
302
309
</details>
303
310
304
311
### Any language code
@@ -379,6 +386,12 @@ There is no way to force the script to remove audio tracks with these codes.
379
386
# (first audio track flagged as Default as it appears in the source file),
380
387
# one English subtitles track and two forced subtitles regardless of
0 commit comments