bug-gnupod
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Bug-gnupod] Some gnupod scripts I wrote


From: Philip Hazelden
Subject: [Bug-gnupod] Some gnupod scripts I wrote
Date: Mon, 17 Aug 2009 14:41:04 +0100

I wrote a couple of scripts for gnupod that I find useful, and am sharing them in hopes that others will as well. They are available in a cloned repository at http://github.com/ChickenProp/gnupod-patches/tree/master , each in separate branches.

The easy-syncing branch contains gnupod_sync.pl, which syncs both the iTunesDB and the OTG data with the GNUtunesDB. It's useful if you intend to work with GNUtunesDB.xml without first using another gnupod_* script. This branch also redirects messages about syncing to STDERR instead of STDOUT, allowing program output to be piped reliably to other scripts. And it adds a reminder to run mktunes.pl when running an OTG sync; this caught me out once when I assumed gnupod_search.pl would be nondestructive. Usage is simply "gnupod_sync.pl [-m mountpoint]".

The dumpsongs branch contains gnupod_dumpsongs.pl, which is an easy way to query GNUtunesDB.xml in a format that can be easily manipulated by the standard unix toolchain. Usage: "gnupod_dumpsongs.pl [-m mountpoint] [-d delimiter] [--playlist name] attribute ..."; it outputs the given attributes in a (by default) tab-delimited list for each song in the DB or playlist. Attributes are simply the names of XML attributes, with the addition of :realpath which gives the absolute path of the file according to the mounting OS.

Neither script is documented yet; I can work on that if it's decided they would be useful additions to the main branch.

reply via email to

[Prev in Thread] Current Thread [Next in Thread]