amaroK partial collection update
Posted by Eric Stein - June 14, 2006 CE @ 00:47:41 UTC
One of the interesting quirks amaroK has is that the automatic collection update (reads metadata from ID3 tags) doesn't reload the data unless the parent directory of the music file has been modified. If you move an mp3 into the directory, this updates the directory's modification time and the file will get scanned. However, if you modify the tags in place with another application (which updates the file's modification time), amaroK will be oblivious. You have to rescan your entire collection for the updates to take effect. Until now, that is.
Note that the ending slash is required - the script was built to work with tab complete.
find * -type d|sed 's/$/\//'|egrep "^($1.*)$"|sed -e "s/^\(.*\)$/\"\1\"/g"|xargs -l1 touch
dcop amarok collection scanCollectionChanges
The above script, once installed, can be used like so:dcop amarok collection scanCollectionChanges
update Folder\ To\ Update\ Recursively/
All music files in the folder and its descendants will be updated in a reasonably short amount of time.Note that the ending slash is required - the script was built to work with tab complete.
Post a Comment