PM123's Remote command reference - Writing meta data

Writing meta data over a remote command instance is done in two steps. First you have to transfer the meta informations to an internal buffer using write meta set commands. Once you have done this, you can apply the changes to one or more songs using the write meta to command. Only fields that have been set using write meta set are overwritten. All other fields are unchanged. Use write meta rst to start over.

write meta set <key>[=<value>]

Transfers a meta data field value to the internal buffer of the remote command engine. This field value will be applied at the next write meta to command. If you omit the value, the field will be set to an empty string; if you omit the value and the equal sign, the tag component key will be removed. This might be something different on e.g. ID3V2 tags.

key must be one of

Escape characters (27) in the value are treated special. <ESC>r is replaced by carriage return (13) and <ESC>n is replaced by a newline (10). All other characters after <ESC> are left as they are, including <ESC> itself. So <ESC><ESC> is replaced by a single <ESC>.

If you are unsure whether another application could have left some old values in the buffer, call write meta rst first. In doubt this is always a good idea, even if you intend to overwrite all meta data keys, because future PM123 releases might support additional tags.

write meta to <url>

Apply the meta data changes previously prepared using write meta set to <url>. Keys that have not been set so far or since the last write meta rst command are left unchanged. They are not removed from the meta info tag.

write meta to might be used multiple times on different targets, to change multiple files, e.g to write the album name of several files in a folder. But you must not use wildcards.

The command returns a success indicator.

0 - OK, meta data changed
400 - Cannot modify meta data of this object, because it does not exist or is not writable.
500 - Plug-in failed to write meta data.

write meta rst [purge]

This command clears all meta data values in the internal buffer and resets all keys to 'do not change'. This is the only way to turn a key set by write meta set into to neutral state.

With the purge option, the information is marked to be purged rather than marked to be unchanged on the write meta to command.

The command returns the previously set values in the same format as info meta.