diff options
author | dd <dd@FreeBSD.org> | 2002-07-28 06:45:30 +0000 |
---|---|---|
committer | dd <dd@FreeBSD.org> | 2002-07-28 06:45:30 +0000 |
commit | 833e15959ca59011b38b7cf26448e69e68f5e88e (patch) | |
tree | e20829cdf8b40d7cb5d79032332a8fc550d14ca7 /sbin/devfs/devfs.8 | |
parent | e3d769e49372f3888a55479a68c112f27766aa23 (diff) | |
download | FreeBSD-src-833e15959ca59011b38b7cf26448e69e68f5e88e.zip FreeBSD-src-833e15959ca59011b38b7cf26448e69e68f5e88e.tar.gz |
Implement this (quoted from the updated man page): If the first token
of a rule specification is a single dash (``-''), rules are read from
the standard input and the rest of the specification is ignored.
Diffstat (limited to 'sbin/devfs/devfs.8')
-rw-r--r-- | sbin/devfs/devfs.8 | 26 |
1 files changed, 26 insertions, 0 deletions
diff --git a/sbin/devfs/devfs.8 b/sbin/devfs/devfs.8 index 11cede3..b22a9ad 100644 --- a/sbin/devfs/devfs.8 +++ b/sbin/devfs/devfs.8 @@ -143,6 +143,10 @@ and the actions determine what should be done when a rule matches a node. For example, a rule can be written that sets the GID to .Li games for all devices with major number 53. +If the first token of a rule specification is a single dash +.Pq Dq - , +rules are read from the standard input and the rest of the specification +is ignored. .Pp The following conditions are recognized. Conditions are ANDed together when matching a device; @@ -311,6 +315,28 @@ will be applied to all nodes. Since hiding all nodes isn't very useful, we can undo like so: .Pp .Dl devfs rule apply unhide +.Pp +which applies +.Cm unhide +to all the nodes, +causing them to reappear. +.Pp +.Dl cat my_rules | devfs rule -s 10 add - +.Pp +Add all the rules from the file +.Pa my_rules +to ruleset 10. +.Pp +.Dl devfs rule -s 20 show | devfs rule -s 10 add - +.Pp +Since +.Cm show +outputs valid rules, +this feature can be used to copy rulesets. +The above copies all the rules from ruleset 20 into ruleset 10. +The rule numbers are preserved, +but ruleset 10 may already have rules with non-conflicting numbers +(these will be preserved). .Sh SEE ALSO .Xr jail 2 , .Xr glob 3 , |