linux-hotplug.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Scott James Remnant <scott@ubuntu.com>
To: linux-hotplug@vger.kernel.org
Subject: Re: RUN
Date: Wed, 11 Jul 2007 08:36:24 +0000	[thread overview]
Message-ID: <1184142984.10213.7.camel@wing-commander> (raw)
In-Reply-To: <4693ECED.9090209@inguin.com>


[-- Attachment #1.1: Type: text/plain, Size: 848 bytes --]

On Tue, 2007-07-10 at 22:11 -0400, Bryan Kadzban wrote:

> Kay Sievers wrote:
> > The question was how to run two programs from a _single_ rule.
> 
> Would duplicate rules (with the same criteria) work?  I.e., something
> like:
> 
> BUS=="scsi", ATTRS{model}=="USB2FlashStorage", SYMLINK+="usbdrive",
> RUN+="/bin/mount /dev/usbdrive"
> BUS=="scsi", ATTRS{model}=="USB2FlashStorage", RUN+="/bin/sh
> /media/usbdrive/test.sh"
> 
> (Where I've fixed the keys to match what udev >= 098 expects.)
> 
You could also use a GOTO/LABEL combination

BUS!="scsi", GOTO="usbdrive_end"
ATTRS{model}!="USB2FlashStorage", GOTO="usbdrive_end"

SYMLINK+="usbdrive"
RUN+="/bin/mount /dev/usbdrive"
RUN+="/bin/sh /media/usbdrive/test.sh"

LABEL="usbdrive_end"

Scott
-- 
Scott James Remnant
Ubuntu Development Manager
scott@ubuntu.com

[-- Attachment #1.2: This is a digitally signed message part --]
[-- Type: application/pgp-signature, Size: 189 bytes --]

[-- Attachment #2: Type: text/plain, Size: 286 bytes --]

-------------------------------------------------------------------------
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/

[-- Attachment #3: Type: text/plain, Size: 226 bytes --]

_______________________________________________
Linux-hotplug-devel mailing list  http://linux-hotplug.sourceforge.net
Linux-hotplug-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/linux-hotplug-devel

  parent reply	other threads:[~2007-07-11  8:36 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2007-07-10 20:32 RUN Adam Kane
2007-07-10 22:01 ` RUN Bauke Jan Douma
2007-07-10 22:08 ` RUN Adam Kane
2007-07-11  0:04 ` RUN Kay Sievers
2007-07-11  0:59 ` RUN Richard Michael
2007-07-11  1:08 ` RUN Kay Sievers
2007-07-11  2:11 ` RUN Bryan Kadzban
2007-07-11  8:36 ` Scott James Remnant [this message]
2007-07-11 13:12 ` RUN Richard Michael
2007-07-13  0:10 ` RUN Adam Kane

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1184142984.10213.7.camel@wing-commander \
    --to=scott@ubuntu.com \
    --cc=linux-hotplug@vger.kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).