renamex is a fast and reliable command-line tool for cleaning, normalizing, and renaming files in bulk.
It provides safe and predictable transformations, including transliteration, string normalization, extension-based filtering, and recursive directory processing.
-
Filename normalization
- Removes invalid characters
- Replaces separators with underscores
- Produces consistent file names
-
Transliteration
- Converts Cyrillic characters to Latin equivalents
-
Extension filtering
- Processes only selected file types
-
Recursive processing
- Traverse directories recursively with
--recursive
- Traverse directories recursively with
-
Safe renaming
- Skips unchanged files
- Prevents overwriting existing files via auto-uniquing
-
Parallel processing
- Efficient handling of large directories using multithreading
-
Dry-run mode
- Preview changes before applying them
cargo install renamexgit clone https://github.com/avtomatik/renamex.git
cd renamex
cargo install --path .renamex [PATH] [OPTIONS]PATH(optional) Directory to process. Defaults to the current working directory.
-
-e, --extensions <EXT>...Filter files by extension (without leading dot) -
-r, --recursiveRecursively process all subdirectories -
-v, --verbosePrint detailed processing output -
--dry-runShow planned changes without modifying files
renamexrenamex -e csv txtrenamex /path/to/directoryrenamex /path/to/directory -rrenamex --dry-run -vrenamex /path/to/directory -r -e csv txt -vотчет_январь.csv
отчет_февраль.csv
пример.txt
renamex -e csv txt -vотчет_январь.csv -> otchet_yanvar.csv
отчет_февраль.csv -> otchet_fevral.csv
пример.txt -> primer.txt
- Processes only regular files
- Supports recursive directory traversal (
--recursive) - Renames files in place
- Never overwrites existing files (auto-resolves collisions)
- Skips files that do not change
- Skips hidden files (starting with
.)
Once installed via:
cargo install renamexyou can run:
renamex --helpcargo build --release
cargo test
cargo fmt --check
cargo clippy -- -D warningsContributions are welcome. Please open an issue or submit a pull request.
MIT License. See LICENSE.md for details.