diff options
Diffstat (limited to '')
| -rw-r--r-- | README.md | 78 |
1 files changed, 26 insertions, 52 deletions
@@ -155,10 +155,8 @@ ${XDG_CONFIG_HOME:-$HOME/.config}/transcode.sh/config.toml Use `--config-file FILE` to load an alternative path, or `--no-config` to skip configuration loading entirely. CLI flags generally take precedence over values -in the config file. Skip codecs are additive by default: configured codecs and -CLI codecs are merged unless `--skip-codec-override` is used. The file must be -valid TOML — an unparseable file is a hard error. Requires `tomlq` when the -file is present. +in the config file. The file must be valid TOML — an unparseable file is a hard +error. Requires `tomlq` when the file is present. **Example `config.toml`:** @@ -166,11 +164,14 @@ file is present. [encoding] preset = "av1" nice = 10 -backup_dir = "backups" video_stream = "v:0" -[skip] -codecs = ["av1", "hevc"] +[processing] +skip_codecs = ["av1", "hevc"] +backup_dir = "backups" +only_if_smaller = false +verify_output = true +continue = false [size_report] enabled = true @@ -181,44 +182,22 @@ verbose = false quiet = false ``` -| Section | Key | Type | CLI equivalent | -|---------|-----|------|----------------| -| `[encoding]` | `preset` | string | `-p` | -| `[encoding]` | `nice` | integer | `-N` | -| `[encoding]` | `hwaccel` | string or boolean | `--hwaccel` / `--no-hwaccel` | -| `[encoding]` | `video_stream` | string | `--video-stream` | -| `[encoding]` | `backup_dir` | string | `--backup-dir` | -| `[encoding]` | `verify_output` | boolean | `--verify-output` | -| `[skip]` | `codecs` | array of strings | `-S` / `--skip-codec-override` | -| `[size_report]` | `enabled` | boolean | `-s` / `--no-size-report` | -| `[size_report]` | `file` | string | `--size-report-file` | -| `[output]` | `ffmpeg_loglevel` | string | `--ffmpeg-loglevel` | -| `[output]` | `quiet` | boolean | `-q` | -| `[output]` | `verbose` | boolean | `-v` | - -> **Note:** `[skip] codecs` from the config file and `--skip-codec` from the -> CLI are **merged** by default — both sources contribute to the skip list. Use -> `--skip-codec-override` to ignore configured skip codecs and use only codecs -> provided through `--skip-codec` for that run. - -> **Note:** `[encoding] hwaccel` accepts `false` (disable), `true` (use `auto`), -> or a method string such as `"vaapi"` or `"cuda"`. CLI `--hwaccel`/`--no-hwaccel` -> always takes precedence. - -> **Note:** `[encoding] backup_dir` must point to an existing directory. CLI -> `--backup-dir` always takes precedence. - -> **Note:** `[encoding] video_stream` selects the input video stream that is -> probed for preset helper variables. It defaults to `"v:0"`. Invalid config -> values are ignored with a warning and the default is used. CLI -> `--video-stream` always takes precedence. This setting does not change ffmpeg -> stream mapping in presets. - -### Codec skip list (deprecated) - -The legacy `skip.conf` file is no longer read. If it still exists, a -deprecation warning is printed at startup. Migrate its contents to -`[skip] codecs` in `config.toml` and delete the old file. +| Section | Key | Type | CLI equivalent | Note | +|---------|-----|------|----------------|------| +| `[encoding]` | `preset` | string | `-p` | | +| `[encoding]` | `nice` | integer | `-N` | | +| `[encoding]` | `hwaccel` | string or boolean | `--hwaccel` / `--no-hwaccel` | Accepts `false` (disable), `true` (use `auto`), or a method string such as `"vaapi"` or `"cuda"`| +| `[encoding]` | `video_stream` | string | `--video-stream` | Selects the input video stream that is probed for preset helper variables. It defaults to `"v:0"`. Invalid config values are ignored with a warning and the default is used. This setting does not change ffmpeg stream mapping in presets. | +| `[processing]` | `skip_codecs` | array of strings | `-S` / `--skip-codec-override` | Codecs defined here and codecs defined using `--skip-codec` from the CLI are **merged** by default. Use `--skip-codec-override` to ignore configured skip codecs and use only codecs provided through `--skip-codec` for that run. | +| `[processing]` | `backup_dir` | string | `--backup-dir` | Must point to an existing directory. | +| `[processing]` | `only_if_smaller` | boolean | `--only-if-smaller` / `--no-only-if-smaller` | | +| `[processing]` | `verify_output` | boolean | `--verify-output` / `--no-verify-output` | | +| `[processing]` | `continue` | boolean | `--continue` / `--no-continue` | | +| `[size_report]` | `enabled` | boolean | `-s` / `--no-size-report` | | +| `[size_report]` | `file` | string | `--size-report-file` | | +| `[output]` | `ffmpeg_loglevel` | string | `--ffmpeg-loglevel` | | +| `[output]` | `quiet` | boolean | `-q` | | +| `[output]` | `verbose` | boolean | `-v` | | ## Usage @@ -244,17 +223,12 @@ transcode.sh [OPTION] [--] FILE... | `--no-hwaccel` | Disable hardware acceleration (omit `-hwaccel` from ffmpeg invocation) | | `--video-stream STREAM_SELECTOR`, `--video-stream=STREAM_SELECTOR` | Select the input video stream to probe for preset helper variables, e.g. `v:0` or `v:1` (default: `v:0`) | -### Skip options - -| Option | Description | -|--------|-------------| -| `-S LIST`, `--skip-codec LIST`, `--skip-codec=LIST` | Add codecs to the effective skip list (comma/space/colon separated) | -| `--skip-codec-override` | Use only codecs from `--skip-codec`, ignoring `[skip].codecs` from config | - ### Processing options | Option | Description | |--------|-------------| +| `-S LIST`, `--skip-codec LIST`, `--skip-codec=LIST` | Add codecs to the effective skip list (comma/space/colon separated) | +| `--skip-codec-override` | Use only codecs from `--skip-codec`, ignoring `[processing].skip_codecs` from config | | `-n`, `--dry-run` | Show what would be done; don't run ffmpeg | | `--backup-dir DIR`, `--backup-dir=DIR` | Copy originals to an existing backup directory before replacing them | | `-l`, `--only-if-smaller` | Only replace original if new file is smaller | |
