CHGRP(1) CHGRP(1)
NAME
chgrp - change group ownership of files
SYNOPSIS
chgrp[options] group file...
POSIX options: [-R][--]
POSIX 1003.1-2001 options: [-hHLPR]
GNU group denotation: [--reference=rfile]
GNU options (shortest form): [-cfvR][--help][--version][--]
DESCRIPTION
chgrp changes the group ownership of each given file to group, which
can be either a group name or a numeric group ID.
POSIXOPTIONS
-R Recursively change the group ownership of directories and their
contents. (And continue even when errors are encountered.)
-- Terminate option list.
AUSTINDRAFTOPTIONS
-h For each file operand given that is a symlink, change the group
ownership of the symlink itself, rather than the object it
points to. If the system does not support a group ownership for
symlinks, do nothing for a symlink.
-H (half-logical)
(When given together with -R.) For each file operand given that
is a symlink to a directory, change the group ownership of the
directory and all files in the file hierarchy below it.
-L (logical)
(When given together with -R.) For each file, either command
line operand or encountered during the tree walk, that is a sym-
link to a directory, change the group ownership of the directory
and all files in the file hierarchy below it.
-P (physical)
(When given together with -R.) For each file, either command
line operand or encountered during the tree walk, that is a sym-
link, change the group ownership of the symlink itself, rather
than the object it points to. If the system does not support a
group ownership for symlinks, do nothing for a symlink. This is
the default.
-R Recursively change the group ownership of directories and their
contents.
ADDITIONALGNUDESCRIPTION
A GNU extension (new in fileutils 4.0) allows one to use --refer-
ence=rfile as a group description: the same group as that of rfile.
GNUOPTIONS
-c,--changes
Verbosely describe the action for each file whose group actually
changes.
-f,--silent,--quiet
Do not print error messages about files whose group cannot be
changed.
-h,--no-dereference
Act on symbolic links themselves instead of what they point to.
Only available if the lchown system call is provided.
-v,--verbose
Verbosely describe the action or non-action taken for every
file.
-R,--recursive
Recursively change the group ownership of directories and their
contents.
GNUSTANDARDOPTIONS
--help Print a usage message on standard output and exit successfully.
--version
Print version information on standard output, then exit success-
fully.
-- Terminate option list.
ENVIRONMENT
The variables LANG, LC_ALL, LC_CTYPE and LC_MESSAGES have the usual
meaning. For an XSI-conforming system: NLSPATH has the usual meaning.
CONFORMINGTO
POSIX 1003.2 only requires the -R option. Use of other options may not
be portable.
NOTES
This page describes chgrp as found in the fileutils-4.0 package; other
versions may differ slightly. Mail corrections and additions to
aeb
cwi.nl. Report bugs in the program to fileutils-
bugs
gnu.edu.
GNU fileutils 4.0 2000-08 CHGRP(1)