mdls <file...>

Lists the metadata attributes for the specified file

Arguments

NameDescription
filefilepaths

Options

NameDescription
--name, -name <attributeName>
  • Repeatable ♾
--raw, -rawPrint raw attribute data in the order that was requested. Fields will be separated with a ASCII NUL character, suitable for piping to xargs(1) -0
--nullMarker, -nullMarkerSets a marker string to be used when a requested attribute is null. Only used in -raw mode. Default is '(null)'
--plist, -plist <stdout or file> <file>Output attributes in XML format to file. Use - to write to stdout option. Incompatible with options -raw, -nullMarker, and -name