Upgrade mdev to allow commands to be run on create/delete.
authorRob Landley <rob@landley.net>
Mon, 26 Jun 2006 14:11:33 +0000 (14:11 -0000)
committerRob Landley <rob@landley.net>
Mon, 26 Jun 2006 14:11:33 +0000 (14:11 -0000)
commitef10d52745a72f524e36edc375a6a05d3365ede4
treebd1ee024e81262ec2485c4d5f391ef910d85bd38
parentcf7577d4171d517690e95e7225979bfde32fce7c
Upgrade mdev to allow commands to be run on create/delete.

Both Jason Schoon and Giuseppe Ciotta deserve credit for this, I used elements
of both.  It's been upgraded so that you can specify that a given command
should run at create, at delete, or at both using different special characters
(@, $, and * respectively).  It uses the system() method of running command
lines which means you can use environment variables on the command line (it
sets $MDEV to the name of the current device being created/deleted, which is
useful if you matched it via regex), and the documentation warns that you need
a /bin/sh to make that work, so you probably want to pick a default shell.
include/usage.h
util-linux/Config.in
util-linux/mdev.c