man lltag (Commandes) - tag mp3/ogg/flac music files automagically

NAME

lltag - tag mp3/ogg/flac music files automagically

SYNOPSIS

lltag [-F <format>] [-G] [-p] [-a <artist>] [-t <title>] [-A <album>] [-n <number>] [-g <genre>] [-y <year>] [-c <comment>] [--spaces] [--maj] [--sep <s1|s2|...>] [--regexp <regexp>] [--mp3/--ogg/--flac] [--clear] [--append] [--no-tagging] [--rename <format>] [--rename-ext] [--rename-min] [--rename-sep <sep>] [--rename-regexp <regexp>] [--dry-run] [--yes] [--ask] [-R] [-v] [--config <file>] [--gencfg <file>] [-S] [--show-tags <tags>] [-L] [-V] [-h]

DESCRIPTION

lltag is a command-line tool to automagically set tags of MP3, OGG or FLAC files. It parses the filenames according to different formats to get the tags. The formats may be either given by the user or guessed by lltag from its internal database.

When called with the -F option (once or multiple times), it will first try the user-specified formats.

Internal formats will be tried later if the -G option was passed.

mp3info is used to tag MP3 files while vorbiscomment is used for OGG files, and metaflac is used for FLAC files.

When called with --rename the target file will also be renamed.

OPTIONS

-A, --album <album>
Set the default value of the Album tag.
-a, --artist <artist>
Set the default value of the Artist tag.
--append
Force appending of ogg/flac tags. See CLEARING, REPLACING OR APPENDING below for details.
--ask
Always ask confirmation to the user before tagging. By default user-specified format matching is accepted while guess format matching is asked for confirmation. See TAGGING CONFIRMATION below for details.
-c, --comment <comment>
Set the default value of the Comment tag.
--clear
Force clearing of id3 tags of mp3 files or flac tags. See CLEARING, REPLACING OR APPENDING below for details.
--config <file>
Parse additional configuration file. See CONFIGURATION FILES below for details.
--dry-run
Do not really tag files, just show what would have been done.
-F, --format <format>
Add the specified format string to the list of user-supplied formats. Might be used several times to try different formats. See FORMAT below for details.
--flac
Tag all files as FLAC files, using metaflac.
-G, --guess
Guess format using the internal database if no user-specified format worked (default behavior).
-g, --genre <genre>
Set the default value of the Genre tag.
--gencfg <file>
Generate configuration file. See CONFIGURATION FILES below for details.
-h, --help
Print a usage message and exit.
-L, --list
List internal formats.
--maj
Upcase the first letter of each word in tags.
--mp3
Tag all files as MP3 files, using mp3info.
-n, --number <number>
Set the default value of the Track Number tag.
--no-tagging
Do not actually tag files. This might be used to rename files without tagging.
--ogg
Tag all files as OGG files, using vorbiscomment.
-p, --nopath
Do not consider the path of files when matching.
-R, --recursive
Recursively search for files in subdirectories.
--regexp <[tag,tag:]s/from/to/>
Replace from with to in tags before tagging. If several tags (comma-separated) prefix the regexp, replacement is only applied to the corresponding fields. This option might be used multiple times to specify multiple replacing.
--rename <format>
After tagging, rename the file according to the format. By default, confirmation is asked before tagging. See RENAMING CONFIRMATION below for details.
--rename-ext
Assume that the file extension is provided by the rename format instead of automatically adding the extension corresponding to the file type.
--rename-min
Lowcase all tags before renaming.
--rename-regexp <[tag,tag:]s/from/to/>
Replace from with to in tags before renaming. If several tags (comma-separated) prefix the regexp, replacement is only applied to the corresponding fields. This option might be used multiple times to specify multiple replacing.
--rename-sep <sep>
Replace spaces with sep when renaming. See --rename-regexp for a more general replace feature.
-S
Instead of tagging, lltag shows the tags that are currently set in files. See --show-tags to show only some tags.
--sep <string|string>
Replace the specified characters or strings with space in tags. They have to be |-separated. See --regexp for a more general replace feature.
--show-tags <tag1,tag2,...>
Instead of tagging, lltag shows tags that are currently set in files. The argument is a comma separated list of tag types (artist, title, album, number, genre, year, comment or all). See also -B to show all tags.
--spaces
Allow multiple or no space instead of only one when matching. Also allow spaces limiting path elements.
-t, --title <title>
Set the default value of the Title tag.
-v, --verbose
Show verbose messages.
-V, --version
Show the version.
-y, --year <year>
Set the default value of the Year tag.
--yes
Always accept tagging without asking the user. By default user-specified format matching is accepted while guess format matching is asked for confirmation.

Also always accept renaming without asking the user.

FORMAT

User-specified formats must be a string composed of any characters and the following special codes:

%a to match the author.

%A to match the album.

%g to match the genre.

%n to match the track number.

%t to match the title.

%y to match the year.

%c to match the comment.

%d to match anything and forget it.

%% to match %.

CLEARING, REPLACING OR APPENDING

Id3 tags of mp3 files are a set of 7 independent fields, while ogg/flac tags is a unique stream of one field per line. That is why mp3 tags may be changed independently while ogg/flac tags may be reset or appended.

Thus, lltag clears ogg tag by default before setting the new ones, while it only replaces mp3 tags.

lltag may either replace (by default), append or reset flac tags since metaflac is flexible enough to do so.

If --clear is passed, all mp3/flac tags will be cleared first. This does not impact ogg tagging since it clears by default.

If --append is passed, ogg/flac tags are appended to the existing ones. This does not impact mp3 tagging since appending is impossible (newly-defined existing tags are replaced, others are kept).

TAGGING CONFIRMATION

When --ask is passed or when guessing, each matching will lead to a confirmation message before tagging. Available behaviors are:

y Tag current file with current format.

v View which tags would be set.

u Tag current file with current format. Then use current format for all remaining matching files. When a non-matching file is reached, stop using this preferred format.

a Tag current file with current format. Then, never asking for a confirmation anymore.

e Edit current fields before tagging, including fields that are non matched by the format, and default values. Editing ends by tagging or canceling (return to confirmation menu).

The behavior depends on the installed readline library. If it is smart, the current value may be edited inline and an history is available. If not, pressing <enter> will keep the current value while CLEAR will empty it.

n Don't tag current file with this format. Try the next matching format on the current file.

p When matching is done through combination of a path parser and a filename parser, keep the filename parser and try the next path parser on the current file.

s Skip the current file, don't tag it at all.

h Show help about confirmation.

RENAMING CONFIRMATION

By default, before renaming, a confirmation is asked to the user. You may bypass it by passing --yes on the command line.

If the rename format uses a field that is not defined, a warning is shown and confirmation is always asked.

Available behaviors when renaming are:

y Rename current file with current new filename.

a Rename current file with current new filename. Then, never asking for a renaming confirmation anymore.

e Edit current new filename before renaming. The behavior depends on the installed readline library. If it is smart, the current value may be edited inline and an history is available.

n Don't rename current file.

h Show help about confirmation.

INTERNAL FORMATS

The internal format database is usually stored in /etc/lltag/formats. The user may override this file by defining a $HOME/.lltag/formats. If this file exists, the system-wide one is ignored.

These files contain entries composed of :

[%n - %a - %t] A title between bracket type = filename The type is either filename or path regexp = %L%N%S-%S%A%S-%S%A%L A format composed of %L for limiting space, %N for numbers, %S for a space, %A for anything (except /), %P for any path and %% for %. indices = n,a,t A list of format letters corresponding to %N or %A field in the previous format (See FORMAT for a list of these letters).

CONFIGURATION FILES

lltag reads some configuration files before parsing command line options. The system-wide configuration file is defined in /etc/lltag/config where all options are documented.

It also reads $HOME/.lltag/config if it exists.

The user may also add another configurable file with --config .

lltag may also generate a configuration with --gencfg .

FILES

/etc/lltag/formats System-wide internal format database. See INTERNAL FORMATS for details. $HOME/.lltag/formats User internal format database. If it exists, the system-wide one is ignored. $HOME/.lltag/edit_history History of last entered values in the edition mode if the Readline library supports this feature. /etc/lltag/config System-wide configuration file, with documentation. See CONFIGURATION FILES for details. $HOME/.lltag/config User configuration file.

AUTHOR

Brice Goglin