Skip to main content

Build Status

Audiobooks from mp3 with broken tags

Fix mp3 files tags to convert them into iTunes/iPhone audiobooks..

  • Fixes sort order.
  • Supports messed encoding like cyrillic Win1251.

Details in my blog's article.

Installation

You should have Python 3.6+ installed.

pip install audiobook-tags

Usage

audiobook-tags [-h] [--encoding ENCODING] [--extension EXTENSION] [--set-tag [SET_TAG ...]] [--track-num TRACK_NUM] [--title-prefix TITLE_PREFIX] [--dry] [folder]

Fixes mp3 tags for iOS audiobooks.

positional arguments:
  folder                Folder to process. By default current folder.

options:
  -h, --help            show this help message and exit
  --mask MASK, -m MASK  Files mask. By default .mp3
  --encoding ENCODING, -e ENCODING
                        mp3 tags encoding. "none" if you do not need mp3 tags encoding fix. By default "cp1251".
  --tag [SET_TAG ...], -t [SET_TAG ...]
                        Change mp3 tag to specified string. Format "tag-name/tag-value".
  --num TRACK_NUM, -n TRACK_NUM
                        Sort files and set mp3 tag `track_num`: TRACK_NUM=`name` - sort by names; TRACK_NUM=`tag-<TAG>` - sort by mp3 tag with name <TAG>.
  --prefix TITLE_PREFIX, -p TITLE_PREFIX
                        Add prefix to title tags. By default `{track:04} - ` if `--num` and no prefix if not.
  --dry, -d             Dry run without changing files.

Example:

audiobook-tags --tag="album_artist/Юрий Заборовский (Ардис)" --num="name" --prefix=""
  • converts all .mp3 files in current folder and subfolders
  • fix encoding supposing that original encoding was Windows 1251
  • change tag album artist.
  • set track_num mp3 tag to file number as ordered by file name. But do not add the track number to the title (--prefix=""").

Development

OS Dependencies

MacOS

brew update brew install libmagic

Python dependencies

Note the dot before ./activate.sh:

. ./activate.sh

Metadata

Release files for audiobook-tags 1.1.1

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for audiobook-tags 1.1.1
File Size Uploaded Provenance Actions
audiobook-tags-1.1.1.tar.gz 3.4 kB Without provenance Details for audiobook-tags-1.1.1.tar.gz

Built distribution (wheel)

Table of built distributions (wheels) for audiobook-tags 1.1.1
File Interpreter ABI Platform Actions
audiobook_tags-1.1.1-py3-none-any.whl Python 3 none any Details for audiobook_tags-1.1.1-py3-none-any.whl

Total release size: 6.9 kB

Release files / audiobook-tags-1.1.1.tar.gz

Download URL audiobook-tags-1.1.1.tar.gz
Size 3.4 kB
Tags Source
SHA-256 checksum
How to use checksums
0c73ac09aa2e342537832e76b3a0b29c360863e4fd916e80c030adc81fb1a3c3
BLAKE2b-256 checksum
How to use checksums
8e3887eb4c7787f9cdc41830a843d82c332f90076b6bf07cefb32012e1453e99
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/4.0.2 CPython/3.11.4

Release files / audiobook_tags-1.1.1-py3-none-any.whl

Download URL audiobook_tags-1.1.1-py3-none-any.whl
Size 3.5 kB
Tags Python 3
SHA-256 checksum
How to use checksums
8516a77285a2a2fdc57fc91244b018bc548fb91990723cc813e3910a189688f8
BLAKE2b-256 checksum
How to use checksums
2c9b86c1230b397fc1e841b3319cb74c8c771eb7d7a6f539c95e42de10feb53f
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/4.0.2 CPython/3.11.4

Security for audiobook-tags 1.1.1

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

No provenance found

None of the files in this release were uploaded with provenance metadata.

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page