GNU bug report logs -
#11043
chmod - new feature - restore default mode regarding the umask value
Previous Next
Full log
Message #14 received at 11043 <at> debbugs.gnu.org (full text, mbox):
Here's a proposed patch to document the
already-existing feature on this point.
From 2defd3856672bacf5c422e616625f13e3a56d9e9 Mon Sep 17 00:00:00 2001
From: Paul Eggert <eggert <at> cs.ucla.edu>
Date: Tue, 27 Mar 2012 08:52:20 -0700
Subject: [PATCH] doc: add chmod examples
* doc/coreutils.texi (chmod invocation): Add examples.
---
doc/coreutils.texi | 18 ++++++++++++++++++
1 files changed, 18 insertions(+), 0 deletions(-)
diff --git a/doc/coreutils.texi b/doc/coreutils.texi
index 835c245..da1ecc5 100644
--- a/doc/coreutils.texi
+++ b/doc/coreutils.texi
@@ -10299,6 +10299,24 @@ Recursively change permissions of directories and their contents.
@exitstatus
+Examples:
+
+@smallexample
+# Change file permissions of FOO to be world readable
+# and user writable, with no other permissions.
+chmod 644 foo
+chmod a=r,u+w foo
+
+# Add user and group execute permissions to FOO.
+chmod +110 file
+chmod ug+x file
+
+# Set file permissions of DIR and subsidiary files to
+# be the umask default, assuming execute permissions for
+# directories and for files already executable.
+chmod -R a=,+rwX dir
+@end smallexample
+
@node touch invocation
@section @command{touch}: Change file timestamps
--
1.7.6.5
This bug report was last modified 6 years and 277 days ago.
Previous Next
GNU bug tracking system
Copyright (C) 1999 Darren O. Benham,
1997,2003 nCipher Corporation Ltd,
1994-97 Ian Jackson.