Looking for suggestion on a way to weekly export to devonthink a list of all music files from folder/music (iTunes)?

Hi all

I know this is a bit out there but would love to get some suggestion from the community on a way to weekly export to devonthink a plain text list of all my music files from either the music folder or even from music (iTunes).

would that way to have a “soft” backup of my files so that in case of a nuclear emergency where all my backups fail I can restore my music library. Does that make any sense :wink:?

should I need a script for that that runs in devonthink or keyboard maestro? What options do you guys think will work?

thx

Z

Hmmm… wouldn’t all backups of your databases also be wiped out in such cases? Or are your databases synchronized to cloud services?

hi again, I realized I may have not been 100% clear. I don’t want to backup the actual files but just a way to dump a list (text) of all music files into a simple text file that will be stored in devonthink. Does that make sense?

thx!

Z

I didn’t try them but maybe these scripts are useful?

https://dougscripts.com/itunes/scripts/ss.php?sp=mxmakeatextlist
https://dougscripts.com/itunes/scripts/ss.php?sp=makeatextlist

thx again

I ended up using keyboard maestro and a bash script inside a macro

#!/usr/bin/env zsh -f

PATH='/usr/local/bin:/usr/bin:/usr/sbin:/sbin:/bin'

zmodload zsh/datetime

TIME=$(strftime "%Y-%m-%d--%H.%M.%S" "$EPOCHSECONDS")

find "/Users/zeltak/Music/Music/Media.localized/" -type f -print | sort -f | sed G \
> "/Users/zeltak/BK/music.txt/Music-File-List-as-of-$TIME.txt"

exit 0

the question still remains for me, what’s the best approach for weekly moving these text files to inside DT? manually/automatically push them to DT or index externally?

thx a lot

Z

You could use a weekly smart rule or reminder which executes an embedded AppleScript. And the AppleScript could execute the necessary shell scripts.