"autorun" type functionality from automounter

Justin Dugger jldugger at gmail.com
Mon Jul 31 10:53:13 CDT 2006


Or if you want something a bit more attached to your user's session
rather than the system, you could investigate dbus/hal.  This is how
GNOME automatically mounts USB drives and CD drives as your user,
among other things.  In fact, one of the options I see under
"Removable Media and Storage" is which command to run when a Portable
Music Player is connected.  It seems to be oriented to playing music
locally, but I see no reason why you can't change the command to do
your sync instead of starting rhythmbox.

Justin Dugger

On 7/25/06, Jason D. Clinton <me at jasonclinton.com> wrote:
> On Tue, 2006-07-25 at 15:05 -0500, Kyle Sexton wrote:
> > I was wondering if anyone had a way to automatically run a command
> > after automounter sees a new device and mounts it.  My goal is to
> > automatically sync over new podcasts to an mp3 player when it's
> > mounted.  I've searched around and haven't seen a simple way to do
> > this.  I'm trying to avoid writing a poller in a cronjob that looks
> > for the device. :)
>
> The way to do it is to use a udev rule.
>
>
>
> -----BEGIN PGP SIGNATURE-----
> Version: GnuPG v1.4.3 (GNU/Linux)
>
> iD8DBQBExnzotSqjk42zvwkRAtIWAJ4iWzkP2GsZqFSpv/vpOv5gX3+E2QCgv/MO
> dkhnAh0ut5NZKa2nK3XKVYE=
> =YRSk
> -----END PGP SIGNATURE-----
>
>
> _______________________________________________
> Kclug mailing list
> Kclug at kclug.org
> http://kclug.org/mailman/listinfo/kclug
>
>
>


More information about the Kclug mailing list