file-normalizer v1.4.2
✨ What's Changed
Project structure
Moved CLI argument parsing to a separate cli.py module. Cleaned up imports and split responsibilities between modules. Simplified several parts of the codebase.
Windows installer
The --install command now works more safely with compiled .exe builds. filenorm is installed to %LOCALAPPDATA%\Filenorm and the installation directory is added to the user's PATH. Windows Registry handling and installation error handling were also cleaned up.
Compound extensions
Moved compound extension handling into its own module. Added support for extensions such as .tar.gz, .tar.bz2, .user.js, .d.ts, .config.json, .min.js, and .log.gz. Compound extensions are checked from longest to shortest to avoid incorrect filename splitting.
Filename normalization
Improved handling of lower, upper, title, and capitalize case styles. Separator handling for snake, kebab, and space was cleaned up. Prefixes and suffixes are now handled more consistently, including duplicate separators.
Safer renaming
filenorm now checks whether the target filename already exists before renaming. Change counters only include successful operations, and filenorm_log.txt is ignored by the normalizer.
Logging
Improved rename history output and error messages when the log file cannot be written. Dry-run changes are also clearly marked in the log.
General cleanup
Removed unnecessary comments and duplicated code. Renamed some variables and functions to make their purpose clearer and cleaned up a few rough edges across the project.