From owner-freebsd-doc@FreeBSD.ORG Mon Apr 15 13:20:00 2013 Return-Path: Delivered-To: freebsd-doc@smarthost.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.FreeBSD.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id DC854221 for ; Mon, 15 Apr 2013 13:20:00 +0000 (UTC) (envelope-from gnats@FreeBSD.org) Received: from freefall.freebsd.org (freefall.freebsd.org [IPv6:2001:1900:2254:206c::16:87]) by mx1.freebsd.org (Postfix) with ESMTP id C3BD0FD6 for ; Mon, 15 Apr 2013 13:20:00 +0000 (UTC) Received: from freefall.freebsd.org (localhost [127.0.0.1]) by freefall.freebsd.org (8.14.6/8.14.6) with ESMTP id r3FDK0OI043810 for ; Mon, 15 Apr 2013 13:20:00 GMT (envelope-from gnats@freefall.freebsd.org) Received: (from gnats@localhost) by freefall.freebsd.org (8.14.6/8.14.6/Submit) id r3FDK0HX043804; Mon, 15 Apr 2013 13:20:00 GMT (envelope-from gnats) Resent-Date: Mon, 15 Apr 2013 13:20:00 GMT Resent-Message-Id: <201304151320.r3FDK0HX043804@freefall.freebsd.org> Resent-From: FreeBSD-gnats-submit@FreeBSD.org (GNATS Filer) Resent-To: freebsd-doc@FreeBSD.org Resent-Reply-To: FreeBSD-gnats-submit@FreeBSD.org, Björn Heidotting Received: from mx1.freebsd.org (mx1.FreeBSD.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id 7E21812F for ; Mon, 15 Apr 2013 13:14:05 +0000 (UTC) (envelope-from nobody@FreeBSD.org) Received: from red.freebsd.org (red.freebsd.org [IPv6:2001:4f8:fff6::22]) by mx1.freebsd.org (Postfix) with ESMTP id 6ED2EF8D for ; Mon, 15 Apr 2013 13:14:05 +0000 (UTC) Received: from red.freebsd.org (localhost [127.0.0.1]) by red.freebsd.org (8.14.5/8.14.5) with ESMTP id r3FDE5n4081245 for ; Mon, 15 Apr 2013 13:14:05 GMT (envelope-from nobody@red.freebsd.org) Received: (from nobody@localhost) by red.freebsd.org (8.14.5/8.14.5/Submit) id r3FDE5GF081240; Mon, 15 Apr 2013 13:14:05 GMT (envelope-from nobody) Message-Id: <201304151314.r3FDE5GF081240@red.freebsd.org> Date: Mon, 15 Apr 2013 13:14:05 GMT From: Björn Heidotting To: freebsd-gnats-submit@FreeBSD.org X-Send-Pr-Version: www-3.1 Subject: docs/177870: [patch] order EXAMPLE section in devfs(8) manpage X-BeenThere: freebsd-doc@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: Documentation project List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 15 Apr 2013 13:20:00 -0000 >Number: 177870 >Category: docs >Synopsis: [patch] order EXAMPLE section in devfs(8) manpage >Confidential: no >Severity: non-critical >Priority: low >Responsible: freebsd-doc >State: open >Quarter: >Keywords: >Date-Required: >Class: doc-bug >Submitter-Id: current-users >Arrival-Date: Mon Apr 15 13:20:00 UTC 2013 >Closed-Date: >Last-Modified: >Originator: Björn Heidotting >Release: FreeBSD 9.1 >Organization: >Environment: >Description: In the devfs(8) manpage: move EXAMPLES descriptions to before the actual command. >How-To-Repeat: >Fix: A patch is included in this report. Patch attached with submission follows: --- devfs.8 2013-04-15 14:54:17.000000000 +0200 +++ devfs_work.8 2013-04-15 14:48:27.000000000 +0200 @@ -269,13 +269,11 @@ .Pa /dev (this only matters for things that might change the properties of nodes). .Pp -.Dl "devfs ruleset 10" -.Pp Specify that ruleset 10 should be the current ruleset for .Pa /dev (if it does not already exist, it is created). .Pp -.Dl "devfs rule add path speaker mode 666" +.Dl "devfs ruleset 10" .Pp Add a rule that causes all nodes that have a path that matches .Dq Li speaker @@ -293,7 +291,7 @@ .Pa atspeaker module is loaded after the above rule is added). .Pp -.Dl "devfs rule applyset" +.Dl "devfs rule add path speaker mode 666" .Pp Apply all the rules in the current ruleset to all the existing nodes. E.g., if the above rule was added after @@ -302,7 +300,7 @@ this command will cause its file mode to be changed to 666 as prescribed by the rule. .Pp -.Dl devfs rule add path "snp*" mode 660 group snoopers +.Dl "devfs rule applyset" .Pp (Quoting the argument to .Cm path @@ -317,7 +315,7 @@ .Xr snp 4 devices. .Pp -.Dl "devfs rule -s 20 add type disk group wheel" +.Dl devfs rule add path "snp*" mode 660 group snoopers .Pp Add a rule to ruleset number 20. Since this ruleset is not the current ruleset for any mount-points, @@ -325,34 +323,34 @@ a current ruleset for some mount-point at a later time). However, it can be applied explicitly, as such: .Pp -.Dl "devfs -m /my/jail/dev rule -s 20 applyset" +.Dl "devfs rule -s 20 add type disk group wheel" .Pp This will apply all rules in ruleset number 20 to the DEVFS mount on .Pa /my/jail/dev . It does not matter that ruleset 20 is not the current ruleset for that mount-point; the rules are still applied. .Pp -.Dl "devfs rule apply hide" +.Dl "devfs -m /my/jail/dev rule -s 20 applyset" .Pp Since this rule has no conditions, the action .Pq Cm hide will be applied to all nodes. Since hiding all nodes is not very useful, we can undo it: .Pp -.Dl "devfs rule apply unhide" +.Dl "devfs rule apply hide" .Pp which applies .Cm unhide to all the nodes, causing them to reappear. .Pp -.Dl "devfs rule -s 10 add - < my_rules" +.Dl "devfs rule apply unhide" .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 -" +.Dl "devfs rule -s 10 add - < my_rules" .Pp Since .Cm show @@ -362,6 +360,8 @@ The rule numbers are preserved, but ruleset 10 may already have rules with non-conflicting numbers (these will be preserved). +.Pp +.Dl "devfs rule -s 20 show | devfs rule -s 10 add -" .Sh SEE ALSO .Xr chmod 1 , .Xr jail 2 , >Release-Note: >Audit-Trail: >Unformatted: