Skip to main content

beets plugin to support user defined keyword tags

Project description

Usertag

A plugin for beets that provides the ability to add custom tags for individual tracks and albums. Big thanks to igordetigor for the original implementation!

This can be used to add additional metadata to your tracks and albums to help categorize your music. For example, adding a tag for albums that you have not listened to yet:

beet addtag -a Dire Straits Brothers In Arms -t listen

And then, when you want to listen to something new, you can list them like this:

beet ls -a usertags:listen

Note that this metadata is not added to the actual files as tags, it only exists in beets' database.

Installation

First, install the package with pip:

pip install beets-usertag

Then, add usertag to the list of plugins in beets' config.yaml file. This is described in more detail in the beets documentation.

Configuration

First, add the plugin to your beets configuration file.

plugins: [..] usertags

Then, add the configuration block. This is only required if you want to automatically add tags on import. The commands will work regardless of the settings here.

usertag:
    auto: yes
    album_tags: foo bar
    item_tags: baz bax

The options are as follows:

  • auto - whether to add tags to albums and tracks on import. Possible values: yes, no. Default: no.
  • album_tags - list of tags to add to albums. Default: none.
  • item_tags - list of tags to add to items (tracks). These will be added to individual items in albums as well as singleton items. Default: none.

Usage

Adding tags

beet addtag <query> -t <tag> [-t <other-tag>]
Flag Description
-t <tag>, --tag <tag> Tag(s) to add to items matching the given query. Additional tags require new flags.
-a, --album (Optional) Whether the query should match albums instead of tracks. Tracks will not be changed.
-p, --prompt (Optional) If set, you will be shown the list of items that will be changed and asked for confirmation.
-i, --inherit (Optional) Used only if -a is set. If set, tags will be added to the album's items as well.

This command also has an alias - adt.

Removing tags

beet rmtag <query> -t <tag> [-t <other-tag>]
Flag Description
-t <tag>, --tag <tag> Tag(s) to remove from items matching the given query. Additional tags require new flags.
-a, --album (Optional) Whether the query should match albums instead of tracks. Tracks will not be changed.
-p, --prompt (Optional) If set, you will be shown the list of items that will be changed and asked for confirmation.
-i, --inherit (Optional) Used only if -a is set. If set, the given tags will be removed from the album's items as well.

This command also has an alias - rmt.


beet cleartags [-a] <query>

This command removes all tags on items/albums that match the given query.

Flag Description
-a, --album (Optional) Whether the query should match albums instead of tracks. Tracks will not be changed.
-p, --prompt (Optional) If set, you will be shown the list of items that will be changed and asked for confirmation.

Listing tags

beet listtags [-a] <query>
Flag Description
-a, --album (Optional) Whether the query should match albums instead of tracks. Tracks will not be changed.

Lists all user-defined tags added to the items matching the given query and the number of items that have each tag.

> beet listtags Artist
foo 1
bar 5

The output means that out of the tracks matching the query Artist one has the tag foo and five tracks have the tag bar.

This command also has an alias - lst.


beet list [-a] usertags:<tag>

Query user tags as you would query any other field with the standard list command. This will list all tracks/albums that have the given tag set. Add the -a flag to list user-tagged albums.


beet list <query> -f '$title - $usertags'

Using list like this will return the tracks matching query and print out their titles and the usertags that have been set on them.

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

beets_usertag-1.0.1.tar.gz (7.6 kB view details)

Uploaded Source

Built Distribution

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

beets_usertag-1.0.1-py3-none-any.whl (6.2 kB view details)

Uploaded Python 3

File details

Details for the file beets_usertag-1.0.1.tar.gz.

File metadata

  • Download URL: beets_usertag-1.0.1.tar.gz
  • Upload date:
  • Size: 7.6 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.12.9

File hashes

Hashes for beets_usertag-1.0.1.tar.gz
Algorithm Hash digest
SHA256 5c27286213a548ea62bdd82ecb4918d7ee7a7d9370a91a260f99820e38b0d523
MD5 9ec9973df1fd3428829ca571bfa1ebac
BLAKE2b-256 3ce5a5af8a2c99345ee9497e6940b6002797a9caa841a36fffad45e7f47988d4

See more details on using hashes here.

Provenance

The following attestation bundles were made for beets_usertag-1.0.1.tar.gz:

Publisher: publish.yml on edgars-supe/beets-usertag

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file beets_usertag-1.0.1-py3-none-any.whl.

File metadata

  • Download URL: beets_usertag-1.0.1-py3-none-any.whl
  • Upload date:
  • Size: 6.2 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.12.9

File hashes

Hashes for beets_usertag-1.0.1-py3-none-any.whl
Algorithm Hash digest
SHA256 f2c3a6dc69573dc5f72c7229db41739798db24afdc7144810aa64c0d2217d7a0
MD5 d76ebe9cb5461bc79ed679b67859cdd7
BLAKE2b-256 9eaeffe160596a528464187f5ac03f3d83bb916b7f9da62f7de682660f10f240

See more details on using hashes here.

Provenance

The following attestation bundles were made for beets_usertag-1.0.1-py3-none-any.whl:

Publisher: publish.yml on edgars-supe/beets-usertag

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

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