Repository navigation
Folders and files
| Name | Name | Last commit date | ||
|---|---|---|---|---|
Repository files navigation
trackupdate v1.2 (c) 2009-2020 - Sean M. Graham This code exists under an MIT license, see LICENSE for details -- trackupdate polls Apple Music every 10 seconds for information about the currently playing track and hands this information to target plugins to perform various tasks. The currently included plugins are: - StdioTarget - Prints the current artist and track to stdout (aka "the terminal") - AudioHijackTarget - Places the current track info into Audio Hijack's "NowPlaying.txt" file - LadioCastTarget - Updates the metadata in Ladiocast using Applescript - ListFileTarget - Creates some text files which can easily be pasted into Mediawiki and HTML, and also creates a simple track list text file - SlackTarget - Posts track info into a Slack channel - TwitterTarget - Posts each track's artist and name to a twitter account specified in the .rc file. Requires that python-twitter is installed (http://code.google.com/p/python-twitter/) Usage: ./trackupdate.py -e 42 # start the show (or reattach) and open the TUI ./trackupdate.py -e 42 --plain # no TUI; engine in the foreground ./trackupdate.py -a -e 42 # regenerate the files from the sqlite db The live engine runs in the background, so closing the TUI (or a crash) leaves the show logging; re-run the same command to reattach. To finish, press Ctrl-C in the TUI and choose "End show": that writes the CUE, track list, wiki and CSV files and stops the engine. The engine's log and socket live in ~/.trackupdate/. Run ./trackupdate.py -h for all options. -a skips rows whose stored ignore flag is set. m3u imports now set it for ignoreAlbum tracks, but episodes imported before that may need their bumper rows marked ignored (in the TUI or web editor) for -a to skip them. trackupdate and some of its plugins require configuration data, which is stored in a file named ~/.trackupdaterc. See example-trackupdaterc for details on the various configuration options. While this script is running, you may notice a persistent bouncing dock icon for python. This annoyed me, so I removed it by editing: /System/Library/Frameworks/Python.framework/Versions/2.5/Resources/Python.app/Contents/Info.plist and adding the following key to the <dict> tag: <key>NSUIElement</key> <string>1</string>