summaryrefslogtreecommitdiff
path: root/transcode.sh.1
diff options
context:
space:
mode:
authorDennis Fink2026-05-16 15:08:15 +0200
committerDennis Fink2026-05-16 15:08:15 +0200
commit7a33be9034e7d950459c7a30a49d544cf36e5270 (patch)
tree3bd6e870bb042f7f122df7d51bb57d90bb5f243b /transcode.sh.1
parent054a300fe5b81ed04f84e902e05c4f4efb95a193 (diff)
downloadtranscode.sh-7a33be9034e7d950459c7a30a49d544cf36e5270.tar.gz
transcode.sh-7a33be9034e7d950459c7a30a49d544cf36e5270.zip
feat(skip): allow overriding config skip codecs
Add --skip-codec-override so users can ignore configured skip codecs for a single run and use only codecs provided through --skip-codec. Defer CLI skip-codec parsing until after config loading so the final skip list can be resolved independently of option order. Document the new override behavior in the README and man page, and add shell completion for the new flag.
Diffstat (limited to '')
-rw-r--r--transcode.sh.132
1 files changed, 28 insertions, 4 deletions
diff --git a/transcode.sh.1 b/transcode.sh.1
index c827336..2dd725a 100644
--- a/transcode.sh.1
+++ b/transcode.sh.1
@@ -151,12 +151,22 @@ in the current working directory.
.BR \-S " \fILIST\fR, " \-\-skip\-codec " \fILIST\fR, " \-\-skip\-codec= \fILIST\fR
Comma-, space- or colon-separated list of video codec names to skip.
Files whose detected input codec appears in this list are left untouched.
-Codecs specified here are merged with any codecs listed under
+By default, codecs specified here are merged with any codecs listed under
.B [skip] codecs
in
.B config.toml
\(em both sources contribute to the skip list.
.TP
+.BR \-\-skip\-codec\-override
+Ignore codecs listed under
+.B [skip] codecs
+in
+.B config.toml
+and use only codecs provided through
+.BR \-S / \-\-skip\-codec
+for this run. The position of this flag on the command line does not matter;
+it changes how the final skip list is resolved after all options are parsed.
+.TP
.BR \-l ", " \-\-only\-if\-smaller
After encoding, replace the original only when the new file is strictly
smaller. If the transcoded file is larger the temporary file is removed
@@ -358,8 +368,10 @@ sources.
.TP
.IR "${XDG_CONFIG_HOME:-$HOME/.config}/transcode.sh/config.toml"
Optional TOML configuration file. Provides defaults for all options.
-CLI flags always take precedence. The file must be valid TOML; an
-unparseable file is a hard error. Requires
+CLI flags generally take precedence. Skip codecs are additive by default:
+configured codecs and CLI codecs are merged unless
+.BR \-\-skip\-codec\-override
+is used. The file must be valid TOML; an unparseable file is a hard error. Requires
.BR tomlq (1).
Supported sections and keys:
.RS
@@ -400,7 +412,11 @@ CLI \fB--backup-dir\fR takes precedence.
.TP
.B [skip] codecs
Array of strings. Merged with any codecs from
-.BR \-S .
+.BR \-S
+by default. Use
+.BR \-\-skip\-codec\-override
+to ignore this configured list and use only codecs provided through
+.BR \-S / \-\-skip\-codec .
.TP
.B [size_report] enabled
Boolean. Equivalent to
@@ -492,6 +508,14 @@ transcode.sh \-N 10 \-S av1 input.mkv
.fi
.RE
.PP
+Temporarily replace configured skip codecs with only HEVC:
+.PP
+.RS
+.nf
+transcode.sh \-\-skip\-codec\-override \-S hevc input.mkv
+.fi
+.RE
+.PP
Load an alternative configuration file:
.PP
.RS