Skip to main content

Tag music files using your $EDITOR

Project description

vitag

Python License PyPI

A minimal CLI tool inspired by vidir, enabling fast batch editing of audio metadata in your favorite text editor (default is your $EDITOR system var).

Features

  • Collects audio files from given paths
  • Extracts tags using mutagen and writes them into a temp file in a structured json format
  • Lets you edit the json in your preferred text editor
  • Validates changes, detects conflicts, and translates the json updates to audio file tags
  • Supported formats:
    • MP3
    • FLAC

Requirements

Instalation

Install through pip:

$ pip install vitag

Or clone the repository:

$ git clone https://github.com/Tx270/vitag
$ cd vitag
# build locally and install with pip
$ pip install .
# or manually install dependencies and run
$ pip install mutagen typer
$ python3 "./cli.py"

Usage

For more info check --help

vitag [PATH ...] \
    [--recursive -r] \
    [--editor -e TEXT] \
    [--verbose -v] \
    [--extensions -x TEXT]

Examples

# Edit all audio files in a folder
vitag "Omnium Gatherum/"

# Edit all audio files in current directory that have mp3 or wav extensions
vitag --extensions mp3,wav

# Edit multiple paths at once with custom editor
vitag "01 Robot Stop.mp3" "Fishing for Fishies/" -e nano

# Recursive scan (for example useful for albums with many disks)
vitag "Petrodragonic Apocalypse/" -r

The star (*) symbol means that the tag is not the same between all given files

{
  "artist": "King Gizzard",
  "album": "*",
  "genre": "*",
  "year": 2018
}

You can edit, add and remove tags by editing the json

{
  "artist": "King Gizzard",
  "album": "*",
  "genre": "pop",
  "year": 2020
}

In the example above, in all selected files:

  • artist and album tags will stay the same for each file
  • genre tag will be changed to pop regardless of the previous value
  • year tag will be changed to 2020.

Roadmap

  • Extensions:
    • Add --extension option to filter file types
    • Test with more audio formats
    • Add supported audio formats to the README file
  • UI/UX:
    • Add progress bars for loading and saving tags
    • Add better error messages
  • Distribution:
    • Upload package to PyPI
  • Features:
    • Add cover art support

License

See LICENSE

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

vitag-1.2.0.tar.gz (8.3 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

vitag-1.2.0-py3-none-any.whl (6.7 kB view details)

Uploaded Python 3

File details

Details for the file vitag-1.2.0.tar.gz.

File metadata

  • Download URL: vitag-1.2.0.tar.gz
  • Upload date:
  • Size: 8.3 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.13.9

File hashes

Hashes for vitag-1.2.0.tar.gz
Algorithm Hash digest
SHA256 cfd639f3592290b5dfc7c1040999ae2b1af4fe13ba70dd4854c113207100f5c5
MD5 e6b4725f834a09617f3f4e8e7c031865
BLAKE2b-256 ad32bd702a1e03edeb09f8ac2845ddcd93d846b4c59591fcc1aafce779fb638f

See more details on using hashes here.

File details

Details for the file vitag-1.2.0-py3-none-any.whl.

File metadata

  • Download URL: vitag-1.2.0-py3-none-any.whl
  • Upload date:
  • Size: 6.7 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.13.9

File hashes

Hashes for vitag-1.2.0-py3-none-any.whl
Algorithm Hash digest
SHA256 e083b186e65c796cb3ed8e4f1cd6d5d143afee4ab80967aba4aa8f27b3bbf4d4
MD5 ed2fe70f8b53e1589faa7b243210d3dd
BLAKE2b-256 6b0bacbef1f38b3ff000f139770ccb8db805334da962ac34a2ba1a94ef76ef20

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page