Rename music files and album directories automatically
Project description
flacfixer
A program to automatically manage the filenames of your music directory.
Install
git clone https://git.sr.ht/~rensoliemans/flacfixer
pip install .
Or, if you'd like to run linters,
pip install .[dev]
Or, if you want an editable install,
pip install -e .
Run
$ flacfixer --help
usage: flacfixer [-h] (-a | -f) [-n] [-r RECURSE_LEVELS] [-v]
Fix filenames in my music dir
options:
-h, --help show this help message and exit
-a, --albums Fixes album names (directories) in PWD
-f, --filenames Fixes filenames in PWD
-n, --dry-run Perform dry run and output what would be changed
-r RECURSE_LEVELS, --recurse-levels RECURSE_LEVELS
Levels to recurse into. Defaults to 0, current level
-v, --verbose Be verbose. Pass multiple times to increase verbosity
This is specific to my music library and preferences:
Filenames
flacfixer -f changes the filenames of music files. Only flac is
currently supported. The target is {tracknumber} - {title}.flac,
where tracknumber always has length 2. tracknumber and title
are extracted from metadata.
Example: 01 - Rosalyn.flac
Albums
flacfixer -a changes the directory names into the following format:
{album name} [{year}]. Since a directory itself can't have any
metadata, it attempts to parse the title and year from the current
directory format. See
test_album_fixer.py.
Example: Tripping with Nils Frahm [2020]
Contributions
Code style
This project uses black,
ruff and
pre-commit. They are all installed when you
do pip install -e .[dev].
Install pre-commit hooks with
pre-commit install
make commands:
-
make lint: executesblackandruff. This is also more or less whatpre-commitdoes. -
make analyse:make lintandmypy -
make test: unittests -
make check:make analyseandmake test(everything)
Contributing
I'm new to mailing lists with git, but please send patches to ~rensoliemans/flacfixer@lists.sr.ht.
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file flacfixer-2.0.tar.gz.
File metadata
- Download URL: flacfixer-2.0.tar.gz
- Upload date:
- Size: 17.6 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.1.0 CPython/3.12.9
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
3d21ef677c950e861ac06e9fc380248051bd7ebf354cd9ac439aecfa6287001f
|
|
| MD5 |
190814f01e95dff4d91fc75d884cb8c8
|
|
| BLAKE2b-256 |
9c30b8003346cb145e7a5a148cd64d71d964d4b58c07d35e96fa6d1898f6f96b
|
File details
Details for the file flacfixer-2.0-py3-none-any.whl.
File metadata
- Download URL: flacfixer-2.0-py3-none-any.whl
- Upload date:
- Size: 16.9 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.1.0 CPython/3.12.9
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
139dd236c7779330f93f16ebdaa5af176cbdc01dedba4a668ae080fa67a6f314
|
|
| MD5 |
1b768531fbe1a1c3331ba5f8b83734fc
|
|
| BLAKE2b-256 |
fd5c846cac41b1197ecf793e90f2953ce8af1701df698bef15bb3f8b6300560b
|