Translations by Anthony Fok

Anthony Fok has submitted the following strings to this translation. Contributions are visually coded: currently used translations, unreviewed suggestions, rejected suggestions.

101107 of 107 results
523.
Enable and disable shell builtins. Enables and disables builtin shell commands. Disabling allows you to execute a disk command which has the same name as a shell builtin without using a full pathname. Options: -a print a list of builtins showing whether or not each is enabled -n disable each NAME or display a list of disabled builtins -p print the list of builtins in a reusable format -s print only the names of Posix `special' builtins Options controlling dynamic loading: -f Load builtin NAME from shared object FILENAME -d Remove a builtin loaded with -f Without options, each NAME is enabled. To use the `test' found in $PATH instead of the shell builtin version, type `enable -n test'. Exit Status: Returns success unless NAME is not a shell builtin or an error occurs.
2014-08-30
启用和禁用 shell 内建。 启用和禁用 shell 的内建命令。禁用使您能够执行一个和内建 命令同名的磁盘上的命令,而无须使用完整的路径名。 选项: -a 打印一个内建的列表,并显示其中每一个是否启用 -n 禁用每一个 NAME 内建或者显示一个被禁用的内建的列表 -p 以可重用的格式打印一个内建的列表 -s 仅打印Posix `special' 内建的名称 控制动态加载的选项: -f 从共享对象 FILENAME 文件中加载 NAME 内建 -d 删除以 -f 选项加载的内建 不带选项时,每一个 NAME 内建都被启用。 如果要使用 $PATH 中找到的 `test' 而不是 shell 内建的版本, 输入 `enable -n test'。 退出状态: 返回成功,除非 NAME 不是一个 shell 内建或者有错误发生。
525.
Parse option arguments. Getopts is used by shell procedures to parse positional parameters as options. OPTSTRING contains the option letters to be recognized; if a letter is followed by a colon, the option is expected to have an argument, which should be separated from it by white space. Each time it is invoked, getopts will place the next option in the shell variable $name, initializing name if it does not exist, and the index of the next argument to be processed into the shell variable OPTIND. OPTIND is initialized to 1 each time the shell or a shell script is invoked. When an option requires an argument, getopts places that argument into the shell variable OPTARG. getopts reports errors in one of two ways. If the first character of OPTSTRING is a colon, getopts uses silent error reporting. In this mode, no error messages are printed. If an invalid option is seen, getopts places the option character found into OPTARG. If a required argument is not found, getopts places a ':' into NAME and sets OPTARG to the option character found. If getopts is not in silent mode, and an invalid option is seen, getopts places '?' into NAME and unsets OPTARG. If a required argument is not found, a '?' is placed in NAME, OPTARG is unset, and a diagnostic message is printed. If the shell variable OPTERR has the value 0, getopts disables the printing of error messages, even if the first character of OPTSTRING is not a colon. OPTERR has the value 1 by default. Getopts normally parses the positional parameters ($0 - $9), but if more arguments are given, they are parsed instead. Exit Status: Returns success if an option is found; fails if the end of options is encountered or an error occurs.
2014-08-30
解析选项参数。 Getopts 被 shell 过程用于解析可定位的参数作为选项。 OPTSTRING 字符串包含待识别的选项字母;如果一个字母后面跟 着分号,则该选项需要一个参数,而该参数应用空格与选项分开。 每次启动时,getopts 会将下一个选项放到 shell 变量 $name 中,如果 name 变量不存在则先将其初始化,而下一个待处 理的参数序号放入 shell 变量 OPTIND 中。OPTIND 变量在每 次 shell 或者 shell 脚本启动时都被初始化为1。当一个选项要 求有一个参数时,getopts 将参数放入 shell 变量 OPTARG 中。 getopts 有两种报告错误的方法。如果 OPTSTRING 变量的第 一个字符是冒号,getopts 使用沉默错误报告。在这种模式 下,不会打印错误消息。如果看到了一个无效的选项, getopts 将找到的选项字符放至 OPTARG 变量中。如果一个必 须的选项没有找到,getopts 放一个 ':' 到 NAME 变量中并且设 置 OPTARG 变量为找到的选项字符。如果 getopts 不在沉默模 式中,并且遇到了一个无效的选项,getopts 放置一个 '?' 到 NAME 变量中并且取消设定 OPTARG变量。如果必须的选项没有找到, 一个'?'会被放入 NAME变量中,OPTARG 将被取消设定,并且会 打印一个诊断信息。 如果 shell 变量 OPTERR 的值为0,getopts 禁用 错误信息的打印,即使 OPTSTRING 变量的第一个字符不是一 个冒号。OPTERR 的默认值为1. Getopts 通常解析可定位的参数($0 - $9),不过如果提供了 更多的参数,它们反而会被解析。 退出状态: 如果一个选项被找到则返回成功;如果遇到了选项的结尾或者 有错误发生则返回失败。
529.
Display or execute commands from the history list. fc is used to list or edit and re-execute commands from the history list. FIRST and LAST can be numbers specifying the range, or FIRST can be a string, which means the most recent command beginning with that string. Options: -e ENAME select which editor to use. Default is FCEDIT, then EDITOR, then vi -l list lines instead of editing -n omit line numbers when listing -r reverse the order of the lines (newest listed first) With the `fc -s [pat=rep ...] [command]' format, COMMAND is re-executed after the substitution OLD=NEW is performed. A useful alias to use with this is r='fc -s', so that typing `r cc' runs the last command beginning with `cc' and typing `r' re-executes the last command. Exit Status: Returns success or status of executed command; non-zero if an error occurs.
2014-08-30
从历史列表中显示或者执行命令。 fc 被用于从历史列表中列出或者重新编辑并执行命令。 FIRST 和 LAST 变量可以是数字用于指定范围,或者 FIRST 可以是 字符串,意味着以这个字符串打头的最近的一个命令。 选项: -e ENAME 选择使用哪个编辑器。默认的是 FCEDIT, 然后是 EDITOR, 然后是 vi -l 列出行而不编辑 -n 列举时省略行号 -r 反转行的顺序(最新行在前) 用 `fc -s [模式=替换 ...] [命令]' 的格式,COMMAND 命令会在 OLD=NEW 替换之后被重新执行。 r='fc -s' 是一个有用的别名,这样的话输入 `r cc'会执行最后一个以 `cc' 开头的命令,输入 `r'会重新执行最后一个命令。 退出状态: 返回成功,或者执行的命令的状态;如果错误发生则返回非零。
549.
Evaluate conditional expression. This is a synonym for the "test" builtin, but the last argument must be a literal `]', to match the opening `['.
2014-08-30
估值条件表达式。 是内建命令 "test" 的同义词,但是最后一个参数必须是 字符 `]',以匹配起始的 `['。
570.
Execute conditional command. Returns a status of 0 or 1 depending on the evaluation of the conditional expression EXPRESSION. Expressions are composed of the same primaries used by the `test' builtin, and may be combined using the following operators: ( EXPRESSION ) Returns the value of EXPRESSION ! EXPRESSION True if EXPRESSION is false; else false EXPR1 && EXPR2 True if both EXPR1 and EXPR2 are true; else false EXPR1 || EXPR2 True if either EXPR1 or EXPR2 is true; else false When the `==' and `!=' operators are used, the string to the right of the operator is used as a pattern and pattern matching is performed. When the `=~' operator is used, the string to the right of the operator is matched as a regular expression. The && and || operators do not evaluate EXPR2 if EXPR1 is sufficient to determine the expression's value. Exit Status: 0 or 1 depending on value of EXPRESSION.
2014-08-30
执行条件命令。 根据条件表达式 EXPRESSION 的估值返回状态0或1。表达式按照 `test' 内建的相同条件组成,或者可以有下列操作符连接而成: ( EXPRESSION ) 返回 EXPRESSION 表达式的值 ! EXPRESSION 如果 EXPRESSION表达式为假则为真,否则为假 EXPR1 && EXPR2 如果 EXPR1 和 EXPR2 表达式均为真则为真,否则为假 EXPR1 || EXPR2 如果 EXPR1 和 EXPR2 表达式中有一个为真则为真,否则为假 当使用 `==' 和 `!=' 操作符时,操作符右边的字符串被用作模式并且执行一个 匹配。当使用 `=~' 操作符时,操作符右边的字符串被当作正则表达式来进行 匹配。 操作符 && 和 || 将不对 EXPR2 表达式进行估值,如果 EXPR1 表达式足够确定 整个表达式的值。 退出状态: 根据 EXPRESSION 的值为0或1。
571.
Common shell variable names and usage. BASH_VERSION Version information for this Bash. CDPATH A colon-separated list of directories to search for directories given as arguments to `cd'. GLOBIGNORE A colon-separated list of patterns describing filenames to be ignored by pathname expansion. HISTFILE The name of the file where your command history is stored. HISTFILESIZE The maximum number of lines this file can contain. HISTSIZE The maximum number of history lines that a running shell can access. HOME The complete pathname to your login directory. HOSTNAME The name of the current host. HOSTTYPE The type of CPU this version of Bash is running under. IGNOREEOF Controls the action of the shell on receipt of an EOF character as the sole input. If set, then the value of it is the number of EOF characters that can be seen in a row on an empty line before the shell will exit (default 10). When unset, EOF signifies the end of input. MACHTYPE A string describing the current system Bash is running on. MAILCHECK How often, in seconds, Bash checks for new mail. MAILPATH A colon-separated list of filenames which Bash checks for new mail. OSTYPE The version of Unix this version of Bash is running on. PATH A colon-separated list of directories to search when looking for commands. PROMPT_COMMAND A command to be executed before the printing of each primary prompt. PS1 The primary prompt string. PS2 The secondary prompt string. PWD The full pathname of the current directory. SHELLOPTS A colon-separated list of enabled shell options. TERM The name of the current terminal type. TIMEFORMAT The output format for timing statistics displayed by the `time' reserved word. auto_resume Non-null means a command word appearing on a line by itself is first looked for in the list of currently stopped jobs. If found there, that job is foregrounded. A value of `exact' means that the command word must exactly match a command in the list of stopped jobs. A value of `substring' means that the command word must match a substring of the job. Any other value means that the command must be a prefix of a stopped job. histchars Characters controlling history expansion and quick substitution. The first character is the history substitution character, usually `!'. The second is the `quick substitution' character, usually `^'. The third is the `history comment' character, usually `#'. HISTIGNORE A colon-separated list of patterns used to decide which commands should be saved on the history list.
2014-08-30
常用 shell 变量名称和使用。 BASH_VERSION 当前 Bash 的版本信息。 CDPATH 用于 `cd' 命令参数搜索的分号分隔的目录列表 GLOBIGNORE 路径扩展时忽略的文件名匹配模式列表, 以分号分隔。 HISTFILE 您的命令历史存放的文件名称。 HISTFILESIZE 历史文件最多可以保存的行数。 HISTSIZE 一个运行的 shell 最多可以访问的历史命令行数。 HOME 您的登录目录的完整路径。 HOSTNAME 当前主机的主机名。 HOSTTYPE 当前版本的 BASH 在其之上运行的 CPU 类型。 IGNOREEOF 控制 shell 收到文件结束符作为单一输入后的 动作。如果设定这个变量,则它的值是 shell 退出之前在 一个空行上可以连续看到的文件结束符数量(默认为10)。 未设定时,文件结束符标志着输入的结束。 MACHTYPE 描述当前运行 Bash 的系统的字符串。 MAILCHECK Bash 检测新邮件的频率,以秒为单位。 MAILPATH Bash 从中检测新邮件的文件列表,以分号分隔。 OSTYPE 运行 Bash 的 Unix 版本。 PATH 当寻找命令时搜索的目录列表,以冒号分隔。 PROMPT_COMMAND 打印每一个主提示符之前执行的命 令。 PS1 主提示符字符串。 PS2 从提示符字符串。 PWD 当前目录的完整路径。 SHELLOPTS 已启用的 shell 选项列表,以冒号分隔。 TERM 当前终端类型的名称。 TIMEFORMAT 以关键则 `time' 显示的时间统计信息的输出 格式。 auto_resume 非空时,一个单独的命令词会首先被在当前 停止的任务列表中搜索。如果找到则该任务被置于前台。 如果值为 `exact' 则意味着命令词必须精确匹配停止任务 列表中的命令。如果值为 `substring' 则意味着命令词必 须匹配任务的一个子字符串。任何其他的值意味着命令词 必须是停止任务的一个前缀。 histchars 控制历史展开和快速替换的字符。第一个字符是 历史替换字符,通常是 `!'。第二个字符是快速替换字符, 通常是 `^'。第三个是历史注释字符,通常是 `#'。 HISTIGNORE 用于决定哪些命令被存入历史文件的模式 列表,以冒号分隔。
575.
Set and unset shell options. Change the setting of each shell option OPTNAME. Without any option arguments, list all shell options with an indication of whether or not each is set. Options: -o restrict OPTNAMEs to those defined for use with `set -o' -p print each shell option with an indication of its status -q suppress output -s enable (set) each OPTNAME -u disable (unset) each OPTNAME Exit Status: Returns success if OPTNAME is enabled; fails if an invalid option is given or OPTNAME is disabled.
2014-08-30
设定和取消设定 shell 选项。 改变每个 shell 选项 OPTNAME的设定。不带参数 时,列出所有 shell 选项并标注每一个选项是否被 设定。 选项: -o 限制 OPTNAME 为定义用于`set -o' 的选项 -p 打印每个 shell 选项并标注它的状态。 -q 抑制输出 -s 启用(设定)每个 OPTNAME 选项 -u 禁用(取消设定)每个 OPTNAME 选项 退出状态: 如果 OPTNAME 选项被启用则返回成功;如果是 无效的选项或OPTNAME 被禁用则失败。