Is there a command-line program to read tags from .m4a files?

You can do this with the TagEditor project:

tageditor -gf 'kind of sometimes maybe 128k aac.m4a'

Result:

Tag information for "kind of sometimes maybe 128k aac.m4a":
MP4/iTunes tag
 Title             Kind Of... Sometimes... Maybe
 Album             Tough Love
 Artist            Jessie Ware
 Year              2014-10-06
 Record label      PMR Records

Mutagen

Mutagen is a Python module to handle audio metadata. It supports ASF, FLAC, M4A, Monkey's Audio, MP3, Musepack, Ogg Opus, Ogg FLAC, Ogg Speex, Ogg Theora, Ogg Vorbis, True Audio, WavPack and OptimFROG audio files. All versions of ID3v2 are supported, and all standard ID3v2.4 frames are parsed. It can read Xing headers to accurately calculate the bitrate and length of MP3s. ID3 and APEv2 tags can be edited regardless of audio format. It can also manipulate Ogg streams on an individual packet/page level.

There isn't (yet) an Ubuntu package for it, but you can install it via

pip install mutagen

You'll need to install pip if you don't have it already. You can install it using virtualenvwrapper if you want to avoid the need for sudo and avoid possible confusion with the standard Ubuntu package mechanism when it comes to security updates, versions of dependencies etc.

Or you can download and install mutagen manually from here. It's a .tar.gz file (here how to). See also the README file form inside the archive.


AtomicParsley seems to do quite a good job of it. It's available for Ubuntu, and besides reading it also allows for setting tags in a m4a file (see manual page for it).

AtomicParsley file.m4a --textdata

or to see a structure of the tags

AtomicParsley file.m4a --test