chgrp 中文man頁(yè)面
名稱
chgrp - 改變文件的組所有權(quán)
總覽
chgrp [選項(xiàng)] 組文件...
POSIX 選項(xiàng): [-R] [--]
Austin 草擬選項(xiàng): [-hHLPR]
GNU 團(tuán)體指示: [--reference=rfile]
GNU 選項(xiàng) (簡(jiǎn)易格式): [-cfvR] [--help] [--version]
描述
chgrp 為給出的 file(文件) 改變它的組所有權(quán). group(組), 可以是組名和組ID數(shù)字兩者之一.
POSIX 選項(xiàng)
- -R
- 遞歸的改變目錄和它的內(nèi)容的組所有權(quán) (即使遇到錯(cuò)誤也繼續(xù).)
- --
- 結(jié)束選項(xiàng)列表.
AUSTIN 草擬選項(xiàng)
- -h
- 對(duì)于給出的文件是符號(hào)鏈接的, 就改變符號(hào)鏈接的本身,這比改變它指鄉(xiāng)的對(duì)象更好.如果系統(tǒng)不支持符號(hào)鏈接的組所有權(quán),那就對(duì)它不起作用.
- -H (half-logical[半邏輯?])
- (當(dāng)和 -R 一起給出) 給出的文件操作數(shù)書(shū)指向目錄的符號(hào)鏈接時(shí),改變這個(gè)目錄和目錄中文件的組所有權(quán)
- -L (logical[(全)邏輯,想來(lái)是和上面的對(duì)應(yīng)的])
- (當(dāng)和 -R 一起給出.) 給出的文件,不論是命令行操作數(shù)還是遍歷整個(gè)樹(shù),操作數(shù)書(shū)指向目錄的符號(hào)鏈接時(shí), 改變這個(gè)目錄和目錄中文件的組所有權(quán).
- -P (physical)
- (當(dāng)和 -R 一起給出.) 對(duì)于一個(gè)文件,不論是命令行操作數(shù)還是遍歷整個(gè)樹(shù), 是符號(hào)鏈接的,只改變它本身, 優(yōu)于(改變)指向的對(duì)象如果系統(tǒng)不支持符號(hào)鏈接的組所有權(quán),那就對(duì)它不起作用.這是默認(rèn)值.
- -R
- 遞歸的改變目錄和它的內(nèi)容的組所有權(quán)
額外的 GNU 描述
一個(gè) GNU 擴(kuò)展(***的在fileutils 4.0里)允許 --reference=rfile 作為組的描述:和 rfile 一樣的組.
GNU 選項(xiàng)
- -c, --changes
- 詳細(xì)描述對(duì)每一個(gè)文件的動(dòng)作:實(shí)際上改變了哪個(gè)組。
- -f, --silent, --quiet
- 不列出錯(cuò)誤信息.(那些組不能被改變).
- -h, --no-dereference
- 作用于符號(hào)鏈接本身代替它所指向的. 僅可用于 lchown 系統(tǒng)調(diào)用被提供時(shí).
- -v, --verbose
- 詳細(xì)描述作用或沒(méi)作用的所有 文件.
- -R, --recursive
- 遞歸的改變目錄和它的內(nèi)容的組所有權(quán)
GNU 標(biāo)準(zhǔn)選項(xiàng)
- --help
- 顯示使用方法到標(biāo)準(zhǔn)輸出并退出.
- --version
- 顯示版本信息到標(biāo)準(zhǔn)輸出并退出.
環(huán)境變量
有以下變量是有通常的意義的 LANG, LC_ALL, LC_CTYPE 和 LC_MESSAGES.對(duì)于XSI-conforming系統(tǒng):NLSPATH有通常的意義.
符合到
POSIX 1003.2 僅要求 -R 選項(xiàng).使用其它選項(xiàng)不一定有效.
注意
這份 chgrp 描述同樣可以在fileutils-4.0 包中找到; 其它版本也許些微有些差別. 把修正和更新郵到 aeb@cwi.nl. 漏洞報(bào)告郵到 fileutils-bugs@gnu.ai.mit.edu.
#p#
NAME
chgrp - change group ownership
SYNOPSIS
chgrp [OPTION]... GROUP FILE...
chgrp [OPTION]... --reference=RFILE FILE...
DESCRIPTION
Change the group of each FILE to GROUP. With --reference, change the group of each FILE to that of RFILE.
- -c, --changes
- like verbose but report only when a change is made
- --dereference
- affect the referent of each symbolic link, rather than the symbolic link itself (this is the default)
- -h, --no-dereference
- affect each symbolic link instead of any referenced file (useful only on systems that can change the ownership of a symlink)
- --no-preserve-root do not treat `/' specially (the default)
- --preserve-root
- fail to operate recursively on `/'
- -f, --silent, --quiet
- suppress most error messages
- --reference=RFILE
- use RFILE's group rather than the specifying GROUP value
- -R, --recursive
- operate on files and directories recursively
- -v, --verbose
- output a diagnostic for every file processed
The following options modify how a hierarchy is traversed when the -R option is also specified. If more than one is specified, only the final one takes effect.
- -H
- if a command line argument is a symbolic link to a directory, traverse it
- -L
- traverse every symbolic link to a directory encountered
- -P
- do not traverse any symbolic links (default)
- --help
- display this help and exit
- --version
- output version information and exit
AUTHOR
Written by David MacKenzie and Jim Meyering.
REPORTING BUGS
Report bugs to <bug-coreutils@gnu.org>.
COPYRIGHT
Copyright © 2004 Free Software Foundation, Inc.
This is free software; see the source for copying conditions. There is NO warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
SEE ALSO
The full documentation for chgrp is maintained as a Texinfo manual. If the info and chgrp programs are properly installed at your site, the command
- info coreutils chgrp
should give you access to the complete manual.