Applying Tracker templates to folders
If you want to apply a custom layout of attributes and sort orders to existing folders that currently have generic layouts, you’ll need some query templates — one for each filetype you want a custom Tracker layout for.
By default, you should have several of these installed already — take a look in ~/config/settings/Tracker/DefaultQueryTemplates
. Some applications also install new folder templates — for example, RipEnc installs a folder template for MP3 files.
Once you’re happy with your layout, you’ll need a quick way to apply that layout to any folder, which involves copying the attributes of the template folder to the target folder with the copyattr command. Add something like this to your ~/.profile
:
alias mpt="copyattr ~/config/settings/Tracker/DefaultQueryTemplates/audio_x-mpeg"
Now, make sure the target folder is closed and cd to the directory one level above the target. For example, if you want to apply your MP3 template to /boot/home/data/MP3/artists/H/Humperdink
, then close Humperdink and cd to /boot/home/data/MP3/artists/H
. The easiest way to do this is to use a tool like Summon or TermHire, which let you open a Terminal in that folder from the Tracker. Now just type:
mpt Humperdink
When you double-click Humperdink, it will have inherited the layout of your MP3 folder template. You can make aliases for as many Tracker templates as you have installed.