CLI Usage
Medix exposes a single command: medix.
Synopsis
Section titled “Synopsis”medix [OPTIONS] PATHPATH can be a single media file or a directory.
Options
Section titled “Options”| Flag | Short | Description |
|---|---|---|
--output PATH | -o | Output directory. Default: <input>/converted/ |
--recursive | -r | Recurse into subdirectories |
--dry-run | -n | Show what would happen without converting |
--version | Print version and exit | |
--help | -h | Show help and exit |
Examples
Section titled “Examples”Single file
Section titled “Single file”medix video.mp4Directory (non-recursive)
Section titled “Directory (non-recursive)”medix ~/Videos/Only scans files directly under ~/Videos/.
Directory (recursive)
Section titled “Directory (recursive)”medix ~/Videos/ -rScans every subdirectory too.
Custom output directory
Section titled “Custom output directory”medix ~/Videos/ -o ~/Converted/If the directory doesn’t exist, Medix creates it.
Dry run
Section titled “Dry run”medix ~/Videos/ --dry-runShows the mapping of inputs → outputs and the ffmpeg command that would be executed. No files are written. See Dry Run Mode.
Module invocation
Section titled “Module invocation”Medix can also be invoked as a Python module, useful in environments where
PATH shimming isn’t available:
python -m medix /path/to/videos/Output path rules
Section titled “Output path rules”| Scenario | Output location |
|---|---|
File input, no -o | <file_parent>/converted/ |
Directory input, no -o | <input>/converted/ |
Any input with -o <dir> | <dir>/ |
Filename collisions are resolved by appending an incrementing counter, so existing files are never overwritten.
Exit behaviour
Section titled “Exit behaviour”Medix prints a final summary table showing successful and failed files. Any failures include the ffmpeg error output so you can diagnose issues.