From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 11227 invoked by alias); 10 May 2015 17:49:37 -0000 Mailing-List: contact zsh-workers-help@zsh.org; run by ezmlm Precedence: bulk X-No-Archive: yes List-Id: Zsh Workers List List-Post: List-Help: X-Seq: 35073 Received: (qmail 23720 invoked from network); 10 May 2015 17:49:23 -0000 X-Spam-Checker-Version: SpamAssassin 3.3.2 (2011-06-06) on f.primenet.com.au X-Spam-Level: X-Spam-Status: No, score=-1.9 required=5.0 tests=BAYES_00,RCVD_IN_DNSWL_NONE autolearn=ham version=3.3.2 X-Biglobe-Sender: From: Jun T To: zsh-workers@zsh.org Cc: Jun-ichi Takimoto Subject: [PATCH 3/4] improve manual format (ch.22) Date: Mon, 11 May 2015 02:48:49 +0900 Message-Id: <1431280130-26058-4-git-send-email-takimoto-j@kba.biglobe.ne.jp> X-Mailer: git-send-email 1.9.5 (Apple Git-50.3) In-Reply-To: <1431280130-26058-1-git-send-email-takimoto-j@kba.biglobe.ne.jp> References: <1431280130-26058-1-git-send-email-takimoto-j@kba.biglobe.ne.jp> X-Biglobe-Spnum: 58822 From: Jun-ichi Takimoto --- Doc/Zsh/mod_clone.yo | 18 +++++++++-------- Doc/Zsh/mod_complist.yo | 6 +++--- Doc/Zsh/mod_curses.yo | 10 +++++----- Doc/Zsh/mod_parameter.yo | 4 ++-- Doc/Zsh/mod_pcre.yo | 10 +++++----- Doc/Zsh/mod_sched.yo | 4 ++-- Doc/Zsh/mod_stat.yo | 6 ++++-- Doc/Zsh/mod_system.yo | 15 +++++++------- Doc/Zsh/mod_zftp.yo | 26 ++++++++++++------------ Doc/Zsh/mod_zpty.yo | 12 +++++------ Doc/Zsh/mod_zselect.yo | 6 +++--- Doc/Zsh/mod_zutil.yo | 52 ++++++++++++++++++++++++------------------------ 12 files changed, 87 insertions(+), 82 deletions(-) diff --git a/Doc/Zsh/mod_clone.yo b/Doc/Zsh/mod_clone.yo index a0bf42b..02dc5be 100644 --- a/Doc/Zsh/mod_clone.yo +++ b/Doc/Zsh/mod_clone.yo @@ -20,7 +20,8 @@ and non-zero on error. The target of tt(clone) should be an unused terminal, such as an unused virtual console or a virtual terminal created by -xterm -e sh -c 'trap : INT QUIT TSTP; tty; while :; do sleep 100000000; done' +example(xterm -e sh -c 'trap : INT QUIT TSTP; tty; + while :; do sleep 100000000; done') Some words of explanation are warranted about this long xterm command line: when doing clone on a pseudo-terminal, some other session @@ -28,14 +29,15 @@ line: when doing clone on a pseudo-terminal, some other session the terminal. Hence the cloned zsh cannot acquire the pseudo-terminal as a controlling tty. That means two things: - the job control signals will go to the sh-started-by-xterm process - group (that's why we disable INT QUIT and TSTP with trap; otherwise - the while loop could get suspended or killed) +startitemize() +itemiz(the job control signals will go to the sh-started-by-xterm process +group (that's why we disable INT QUIT and TSTP with trap; otherwise +the while loop could get suspended or killed)) +itemiz(the cloned shell will have job control disabled, and the job +control keys (control-C, control-\ and control-Z) will not work.) +enditemize() - the cloned shell will have job control disabled, and the job - control keys (control-C, control-\ and control-Z) will not work. - -This does not apply when cloning to an bf(unused) vc. +This does not apply when cloning to an em(unused) vc. Cloning to a used (and unprepared) terminal will result in two processes reading simultaneously from the same terminal, with diff --git a/Doc/Zsh/mod_complist.yo b/Doc/Zsh/mod_complist.yo index 09b2b4f..164b5b0 100644 --- a/Doc/Zsh/mod_complist.yo +++ b/Doc/Zsh/mod_complist.yo @@ -22,7 +22,7 @@ are highlighted. To turn on highlighting an empty value suffices, in which case all the default values given below will be used. The format of the value of these parameters is the same as used by the GNU version of the tt(ls) command: a colon-separated list of specifications of the form -`var(name)=var(value)'. The var(name) may be one of the following strings, +`var(name)tt(=)var(value)'. The var(name) may be one of the following strings, most of which specify file types for which the var(value) will be used. The strings and their default values are: @@ -167,7 +167,7 @@ is the empty string, a default prompt will be used. The value may contain escapes of the form `tt(%x)'. It supports the escapes `tt(%B)', `tt(%b)', `tt(%S)', `tt(%s)', `tt(%U)', `tt(%u)', `tt(%F)', `tt(%f)', `tt(%K)', `tt(%k)' and -`tt(%{...%})' used also in shell prompts as well as three pairs of +`tt(%{)var(...)tt(%})' used also in shell prompts as well as three pairs of additional sequences: a `tt(%l)' or `tt(%L)' is replaced by the number of the last line shown and the total number of lines in the form `var(number)tt(/)var(total)'; a `tt(%m)' or `tt(%M)' is replaced with @@ -409,6 +409,6 @@ ifnzman(noderef(The zsh/zle Module))\ ). For example, to make the return key leave menu selection without accepting the match currently selected one could call -indent(tt(bindkey -M menuselect '^M' send-break)) +example(bindkey -M menuselect '^M' send-break) after loading the tt(zsh/complist) module. diff --git a/Doc/Zsh/mod_curses.yo b/Doc/Zsh/mod_curses.yo index 7ad772a..8104572 100644 --- a/Doc/Zsh/mod_curses.yo +++ b/Doc/Zsh/mod_curses.yo @@ -21,11 +21,11 @@ xitem(tt(zcurses) tt(position) var(targetwin) var(array)) xitem(tt(zcurses) tt(char) var(targetwin) var(character) ) xitem(tt(zcurses) tt(string) var(targetwin) var(string) ) xitem(tt(zcurses) tt(border) var(targetwin) var(border) ) -xitem(tt(zcurses) tt(attr) var(targetwin) [ var({+/-}attribute) | var(fg_col)tt(/)var(bg_col) ] [...]) -xitem(tt(zcurses) tt(bg) var(targetwin) [ var({+/-}attribute) | var(fg_col)tt(/)var(bg_col) | tt(@)var(char) ] [...]) -xitem(tt(zcurses) tt(scroll) var(targetwin) [ tt(on) | tt(off) | {+/-}var(lines) ]) +xitem(tt(zcurses) tt(attr) var(targetwin) [ [tt(+)|tt(-)]var(attribute) | var(fg_col)tt(/)var(bg_col) ] [...]) +xitem(tt(zcurses) tt(bg) var(targetwin) [ [tt(+)|tt(-)]var(attribute) | var(fg_col)tt(/)var(bg_col) | tt(@)var(char) ] [...]) +xitem(tt(zcurses) tt(scroll) var(targetwin) [ tt(on) | tt(off) | [tt(+)|tt(-)]var(lines) ]) xitem(tt(zcurses) tt(input) var(targetwin) [ var(param) [ var(kparam) [ var(mparam) ] ] ]) -xitem(tt(zcurses) tt(mouse) [ tt(delay) var(num) | {+/-}tt(motion) ]) +xitem(tt(zcurses) tt(mouse) [ tt(delay) var(num) | [tt(+)|tt(-)]tt(motion) ]) xitem(tt(zcurses) tt(timeout) var(targetwin) var(intval)) item(tt(zcurses) tt(querychar) var(targetwin) [ var(param) ])( Manipulate curses windows. All uses of this command should be @@ -135,7 +135,7 @@ turned tt(on) to allow the window to be scrolled. The subcommand tt(input) reads a single character from the window without echoing it back. If var(param) is supplied the character is assigned to the parameter var(param), else it is assigned to the -parameter var(REPLY). +parameter tt(REPLY). If both var(param) and var(kparam) are supplied, the key is read in `keypad' mode. In this mode special keys such as function keys and diff --git a/Doc/Zsh/mod_parameter.yo b/Doc/Zsh/mod_parameter.yo index 09ceba2..9d1dc8b 100644 --- a/Doc/Zsh/mod_parameter.yo +++ b/Doc/Zsh/mod_parameter.yo @@ -151,11 +151,11 @@ item(tt(jobstates))( This associative array gives information about the states of the jobs currently known. The keys are the job numbers and the values are strings of the form -`var(job-state):var(mark):var(pid)tt(=)var(state)tt(...)'. The +`var(job-state)tt(:)var(mark)tt(:)var(pid)tt(=)var(state)...'. The var(job-state) gives the state the whole job is currently in, one of `tt(running)', `tt(suspended)', or `tt(done)'. The var(mark) is `tt(+)' for the current job, `tt(-)' for the previous job and empty -otherwise. This is followed by one `var(pid)tt(=)var(state)' for every +otherwise. This is followed by one `tt(:)var(pid)tt(=)var(state)' for every process in the job. The var(pid)s are, of course, the process IDs and the var(state) describes the state of that process. diff --git a/Doc/Zsh/mod_pcre.yo b/Doc/Zsh/mod_pcre.yo index faada28..d6b4bd1 100644 --- a/Doc/Zsh/mod_pcre.yo +++ b/Doc/Zsh/mod_pcre.yo @@ -31,18 +31,18 @@ PCRE. Upon successful match, if the expression captures substrings within parentheses, -tt(pcre_match) will set the array var($match) to those +tt(pcre_match) will set the array tt(match) to those substrings, unless the tt(-a) option is given, in which case it will set the array var(arr). Similarly, the variable -var(MATCH) will be set to the entire matched portion of the +tt(MATCH) will be set to the entire matched portion of the string, unless the tt(-v) option is given, in which case the variable var(var) will be set. No variables are altered if there is no successful match. A tt(-n) option starts searching for a match from the byte var(offset) position in var(string). If the tt(-b) option is given, -the variable var(ZPCRE_OP) will be set to an offset pair string, +the variable tt(ZPCRE_OP) will be set to an offset pair string, representing the byte offset positions of the entire matched portion -within the var(string). For example, a var(ZPCRE_OP) set to "32 45" indicates +within the var(string). For example, a tt(ZPCRE_OP) set to "32 45" indicates that the matched portion began on byte offset 32 and ended on byte offset 44. Here, byte offset position 45 is the position directly after the matched portion. Keep in mind that the byte position isn't necessarily the same @@ -75,7 +75,7 @@ The tt(zsh/pcre) module makes available the following test condition: startitem() findex(pcre-match) -item(expr tt(-pcre-match) pcre)( +item(var(expr) tt(-pcre-match) var(pcre))( Matches a string against a perl-compatible regular expression. For example, diff --git a/Doc/Zsh/mod_sched.yo b/Doc/Zsh/mod_sched.yo index 2d8d77c..1350b9e 100644 --- a/Doc/Zsh/mod_sched.yo +++ b/Doc/Zsh/mod_sched.yo @@ -8,7 +8,7 @@ startitem() findex(sched) cindex(timed execution) cindex(execution, timed) -xitem(tt(sched) [tt(-o)] [tt(PLUS())]var(hh)tt(:)var(mm)[:var(ss)] var(command) ...) +xitem(tt(sched) [tt(-o)] [tt(PLUS())]var(hh)tt(:)var(mm)[tt(:)var(ss)] var(command) ...) xitem(tt(sched) [tt(-o)] [tt(PLUS())]var(seconds) var(command) ...) item(tt(sched) [ tt(-)var(item) ])( Make an entry in the scheduled list of commands to execute. @@ -54,7 +54,7 @@ tt(sched) builtin. The indices of the array correspond to the numbers shown when tt(sched) is run with no arguments (provided that the tt(KSH_ARRAYS) option is not set). The value of the array consists of the scheduled time in seconds since the epoch -(see ifnzman(The zsh/datetime Module)\ +(see ifnzman(noderef(The zsh/datetime Module))\ ifzman(the section `The zsh/datetime Module') for facilities for using this number), followed by a colon, followed by any options (which may be empty but will be preceded by a `tt(-)' otherwise), diff --git a/Doc/Zsh/mod_stat.yo b/Doc/Zsh/mod_stat.yo index 1c540bb..78649de 100644 --- a/Doc/Zsh/mod_stat.yo +++ b/Doc/Zsh/mod_stat.yo @@ -9,9 +9,11 @@ findex(zstat) findex(stat) cindex(files, listing) cindex(files, examining) -xitem(tt(zstat) [ tt(-gnNolLtTrs) ] [ tt(-f) var(fd) ] \ +redef(SPACES)(0)(tt(ifztexi(NOTRANS(@ @ @ @ @ @ ))ifnztexi( ))) +xitem(tt(zstat )[ tt(-gnNolLtTrs) ] [ tt(-f) var(fd) ] \ [ tt(-H) var(hash) ] [ tt(-A) var(array) ] \ - [ tt(-F) var(fmt) ] [ tt(PLUS())var(element) ] [ var(file) ... ]) + [ tt(-F) var(fmt) ]) +xitem(SPACES()[ tt(PLUS())var(element) ] [ var(file) ... ]) item(tt(stat) var(...))( The command acts as a front end to the tt(stat) system call (see manref(stat)(2)). The same command is provided with two names; as diff --git a/Doc/Zsh/mod_system.yo b/Doc/Zsh/mod_system.yo index 7101e37..7f9c011 100644 --- a/Doc/Zsh/mod_system.yo +++ b/Doc/Zsh/mod_system.yo @@ -8,7 +8,7 @@ subsect(Builtins) startitem() findex(syserror) -item(tt(syserror) tt([ -e) var(errvar) tt(] [ -p) var(prefix) tt(] [) var(errno) tt(|) var(errname) tt(]))( +item(tt(syserror) [ tt(-e) var(errvar) ] [ tt(-p) var(prefix) ] [ var(errno) | var(errname) ])( This command prints out the error message associated with var(errno), a system error number, followed by a newline to standard error. @@ -29,11 +29,12 @@ parameters, and a return status of 2 indicates the error name was not recognised (no message is printed for this). ) findex(sysread) -xitem(tt(sysread [ -c) var(countvar) tt(] [ -i) var(infd) tt(] [ -o) var(outfd) tt(])) -item( tt([ -s) var(bufsize) tt(] [ -t) var(timeout) tt(] [) var(param) tt(]))( +redef(SPACES)(0)(tt(ifztexi(NOTRANS(@ @ @ @ @ @ @ @ ))ifnztexi( ))) +xitem(tt(sysread )[ tt(-c) var(countvar) ] [ tt(-i) var(infd) ] [ tt(-o) var(outfd) ]) +item(SPACES()[ tt(-s) var(bufsize) ] [ tt(-t) var(timeout) ] [ var(param) ])( Perform a single system read from file descriptor var(infd), or zero if that is not given. The result of the read is stored in var(param) or -var(REPLY) if that is not given. If var(countvar) is given, the number +tt(REPLY) if that is not given. If var(countvar) is given, the number of bytes read is assigned to the parameter named by var(countvar). The maximum number of bytes read is var(bufsize) or 8192 if that is not @@ -88,7 +89,7 @@ usual rules; no write to var(outfd) is attempted. ) enditem() ) -item(tt(syswrite [ -c) var(countvar) tt(] [ -o) var(outfd) tt(]) var(data))( +item(tt(syswrite) [ tt(-c) var(countvar) ] [ tt(-o) var(outfd) ] var(data))( The data (a single string of bytes) are written to the file descriptor var(outfd), or 1 if that is not given, using the tt(write) system call. Multiple write operations may be used if the first does not write all @@ -109,7 +110,7 @@ to the command, or 2 for an error on the write; no error message is printed in the last case, but the parameter tt(ERRNO) will reflect the error that occurred. ) -xitem(tt(zsystem flock [ -t) var(timeout) tt(] [ -f) var(var) tt(] [-er]) var(file)) +xitem(tt(zsystem flock) [ tt(-t) var(timeout) ] [ tt(-f) var(var) ] [tt(-er)] var(file)) item(tt(zsystem flock -u) var(fd_expr))( The builtin tt(zsystem)'s subcommand tt(flock) performs advisory file locking (via the manref(fcntl)(2) system call) over the entire contents @@ -126,7 +127,7 @@ the subshell exits. Status 0 is returned if the lock succeeds, else status 1. In the second form the file descriptor given by the arithmetic -expression tt(fd_expr) is closed, releasing a lock. The file descriptor +expression var(fd_expr) is closed, releasing a lock. The file descriptor can be queried by using the `tt(-f) var(var)' form during the lock; on a successful lock, the shell variable var(var) is set to the file descriptor used for locking. The lock will be released if the diff --git a/Doc/Zsh/mod_zftp.yo b/Doc/Zsh/mod_zftp.yo index de53cdb..fd99703 100644 --- a/Doc/Zsh/mod_zftp.yo +++ b/Doc/Zsh/mod_zftp.yo @@ -128,15 +128,15 @@ item(tt(cdup))( Change the remote directory to the one higher in the directory tree. Note that tt(cd ..) will also work correctly on non-UNIX systems. ) -item(tt(dir) [ var(args...) ])( -Give a (verbose) listing of the remote directory. The var(args) are +item(tt(dir) [ var(arg) ... ])( +Give a (verbose) listing of the remote directory. The var(arg)s are passed directly to the server. The command's behaviour is implementation -dependent, but a UNIX server will typically interpret var(args) as +dependent, but a UNIX server will typically interpret var(arg)s as arguments to the tt(ls) command and with no arguments return the result of `tt(ls -l)'. The directory is listed to standard output. ) -item(tt(ls) [ var(args) ])( -Give a (short) listing of the remote directory. With no var(args), +item(tt(ls) [ var(arg) ... ])( +Give a (short) listing of the remote directory. With no var(arg), produces a raw list of the files in the directory, one per line. Otherwise, up to vagaries of the server implementation, behaves similar to tt(dir). @@ -164,8 +164,8 @@ item(tt(mode) [ tt(S) | tt(B) ])( Set the mode type to stream (tt(S)) or block (tt(B)). Stream mode is the default; block mode is not widely supported. ) -xitem(tt(remote) var(files...)) -item(tt(local) [ var(files...) ])( +xitem(tt(remote) var(file) ...) +item(tt(local) [ var(file) ... ])( Print the size and last modification time of the remote or local files. If there is more than one item on the list, the name of the file is printed first. The first number is the file size, the second @@ -185,15 +185,15 @@ arguments, in which case the information comes from examining file descriptor zero. This is the same file as seen by a tt(put) command with no further redirection. ) -item(tt(get) var(file) [...])( +item(tt(get) var(file) ...)( Retrieve all var(file)s from the server, concatenating them and sending them to standard output. ) -item(tt(put) var(file) [...])( +item(tt(put) var(file) ...)( For each var(file), read a file from standard input and send that to the remote host with the given name. ) -item(tt(append) var(file) [...])( +item(tt(append) var(file) ...)( As tt(put), but if the remote var(file) already exists, data is appended to it instead of overwriting it. ) @@ -206,7 +206,7 @@ useful for appending to an incomplete local file. However, note that this ability is not universally supported by servers (and is not quite the behaviour specified by the standard). ) -item(tt(delete) var(file) [...])( +item(tt(delete) var(file) ...)( Delete the list of files on the server. ) item(tt(mkdir) var(directory))( @@ -218,11 +218,11 @@ Delete the directory var(directory) on the server. item(tt(rename) var(old-name) var(new-name))( Rename file var(old-name) to var(new-name) on the server. ) -item(tt(site) var(args...))( +item(tt(site) var(arg) ...)( Send a host-specific command to the server. You will probably only need this if instructed by the server to use it. ) -item(tt(quote) var(args...))( +item(tt(quote) var(arg) ...)( Send the raw FTP command sequence to the server. You should be familiar with the FTP command set as defined in RFC959 before doing this. Useful commands may include tt(STAT) and tt(HELP). Note also diff --git a/Doc/Zsh/mod_zpty.yo b/Doc/Zsh/mod_zpty.yo index de47115..340f983 100644 --- a/Doc/Zsh/mod_zpty.yo +++ b/Doc/Zsh/mod_zpty.yo @@ -5,7 +5,7 @@ The tt(zsh/zpty) module offers one builtin: startitem() findex(zpty) -item(tt(zpty) [ tt(-e) ] [ tt(-b) ] var(name) [ var(arg ...) ])( +item(tt(zpty) [ tt(-e) ] [ tt(-b) ] var(name) [ var(arg) ... ])( The arguments following var(name) are concatenated with spaces between, then executed as a command, as if passed to the tt(eval) builtin. The command runs under a newly assigned pseudo-terminal; this is useful for @@ -19,18 +19,18 @@ characters are echoed. With the tt(-b) option, input to and output from the pseudo-terminal are made non-blocking. ) -item(tt(zpty) tt(-d) [ var(names) ... ])( +item(tt(zpty) tt(-d) [ var(name) ... ])( The second form, with the tt(-d) option, is used to delete commands previously started, by supplying a list of their var(name)s. If no -var(names) are given, all commands are deleted. Deleting a command causes +var(name) is given, all commands are deleted. Deleting a command causes the HUP signal to be sent to the corresponding process. ) -item(tt(zpty) tt(-w) [ tt(-n) ] var(name) [ var(strings ...) ])( +item(tt(zpty) tt(-w) [ tt(-n) ] var(name) [ var(string) ... ])( The tt(-w) option can be used to send the to command var(name) the given -var(strings) as input (separated by spaces). If the tt(-n) option is +var(string)s as input (separated by spaces). If the tt(-n) option is em(not) given, a newline is added at the end. -If no var(strings) are provided, the standard input is copied to the +If no var(string) is provided, the standard input is copied to the pseudo-terminal; this may stop before copying the full input if the pseudo-terminal is non-blocking. diff --git a/Doc/Zsh/mod_zselect.yo b/Doc/Zsh/mod_zselect.yo index a374b2c..e065157 100644 --- a/Doc/Zsh/mod_zselect.yo +++ b/Doc/Zsh/mod_zselect.yo @@ -7,7 +7,7 @@ startitem() findex(zselect) cindex(select, system call) cindex(file descriptors, waiting for) -item(tt(zselect) [ tt(-rwe) tt(-t) var(timeout) tt(-a) var(array) ] [ var(fd) ... ])( +item(tt(zselect) [ tt(-rwe) ] [ tt(-t) var(timeout) ] [ tt(-a) var(array) ] [ tt(-A) var(assoc) ] [ var(fd) ... ])( The tt(zselect) builtin is a front-end to the `select' system call, which blocks until a file descriptor is ready for reading or writing, or has an error condition, with an optional timeout. If this is not available on @@ -39,7 +39,7 @@ zselect with no file descriptors and a non-zero timeout for use as a finer-grained replacement for `sleep'; note, however, the return status is always 1 for a timeout. -The option `tt(-a) var(array)' indicates that tt(array) should be set to +The option `tt(-a) var(array)' indicates that var(array) should be set to indicate the file descriptor+LPAR()s+RPAR() which are ready. If the option is not given, the array tt(reply) will be used for this purpose. The array will @@ -52,7 +52,7 @@ might return immediately with status 0 and tt($reply) containing `tt(-r 0 -w operations. The option `tt(-A) var(assoc)' indicates that the associative array -tt(assoc) should be set to indicate the file descriptor+LPAR()s+LPAR() +var(assoc) should be set to indicate the file descriptor+LPAR()s+RPAR() which are ready. This option overrides the option tt(-a), nor will tt(reply) be modified. The keys of tt(assoc) are the file descriptors, and the corresponding values are any of the characters `tt(rwe)' to indicate diff --git a/Doc/Zsh/mod_zutil.yo b/Doc/Zsh/mod_zutil.yo index 7e89111..fd6f2f3 100644 --- a/Doc/Zsh/mod_zutil.yo +++ b/Doc/Zsh/mod_zutil.yo @@ -8,11 +8,11 @@ The tt(zsh/zutil) module only adds some builtins: startitem() findex(zstyle) xitem(tt(zstyle) [ tt(-L) [ var(pattern) [ var(style) ] ] ]) -xitem(tt(zstyle) [ tt(-e) | tt(-) | tt(-)tt(-) ] var(pattern) var(style) var(strings) ...) -xitem(tt(zstyle -d) [ var(pattern) [ var(styles) ... ] ]) +xitem(tt(zstyle) [ tt(-e) | tt(-) | tt(-)tt(-) ] var(pattern) var(style) var(string) ...) +xitem(tt(zstyle -d) [ var(pattern) [ var(style) ... ] ]) xitem(tt(zstyle -g) var(name) [ var(pattern) [ var(style) ] ]) -xitem(tt(zstyle -abs) var(context) var(style) var(name) [ var(sep) ]) -xitem(tt(zstyle -Tt) var(context) var(style) [ var(strings) ...]) +xitem(tt(zstyle -){tt(a)|tt(b)|tt(s)} var(context) var(style) var(name) [ var(sep) ]) +xitem(tt(zstyle -){tt(T)|tt(t)} var(context) var(style) [ var(string) ... ]) item(tt(zstyle -m) var(context) var(style) var(pattern))( This builtin command is used to define and lookup styles. Styles are pairs of names and values, where the values consist of any number of @@ -40,16 +40,16 @@ against the string supplied as the pattern for the context; note that this means, for example, `tt(zstyle -L ":completion:*")' will match any supplied pattern beginning `tt(:completion:)', not just tt(":completion:*"): use tt(":completion:\*") to match that. -The optional second argument limits the output to a specific style (not a +The optional second argument limits the output to a specific var(style) (not a pattern). tt(-L) is not compatible with any other options. The other forms are the following: startitem() -item(tt(zstyle) [ tt(-) | tt(-)tt(-) | tt(-e) ] var(pattern) var(style) var(strings) ...)( +item(tt(zstyle) [ tt(-) | tt(-)tt(-) | tt(-e) ] var(pattern) var(style) var(string) ...)( vindex(reply, use of) -Defines the given var(style) for the var(pattern) with the var(strings) as -the value. If the tt(-e) option is given, the var(strings) will be +Defines the given var(style) for the var(pattern) with the var(string)s as +the value. If the tt(-e) option is given, the var(string)s will be concatenated (separated by spaces) and the resulting string will be evaluated (in the same way as it is done by the tt(eval) builtin command) when the style is looked up. In this case the parameter @@ -58,16 +58,16 @@ evaluation. Before evaluating the value, tt(reply) is unset, and if it is still unset after the evaluation, the style is treated as if it were not set. ) -item(tt(zstyle -d) [ var(pattern) [ var(styles) ... ] ])( +item(tt(zstyle -d) [ var(pattern) [ var(style) ... ] ])( Delete style definitions. Without arguments all definitions are deleted, with a var(pattern) all definitions for that pattern are deleted and if -any var(styles) are given, then only those styles are deleted for the +any var(style)s are given, then only those styles are deleted for the var(pattern). ) item(tt(zstyle -g) var(name) [ var(pattern) [ var(style) ] ])( Retrieve a style definition. The var(name) is used as the name of an array in which the results are stored. Without -any further arguments, all var(patterns) defined are returned. With a +any further arguments, all patterns defined are returned. With a var(pattern) the styles defined for that pattern are returned and with both a var(pattern) and a var(style), the value strings of that combination is returned. @@ -93,14 +93,14 @@ The value is stored in var(name) as an array. If var(name) is declared as an associative array, the first, third, etc. strings are used as the keys and the other strings are used as the values. ) -xitem(tt(zstyle -t) var(context) var(style) [ var(strings) ...]) -item(tt(zstyle -T) var(context) var(style) [ var(strings) ...])( +xitem(tt(zstyle -t) var(context) var(style) [ var(string) ... ]) +item(tt(zstyle -T) var(context) var(style) [ var(string) ... ])( Test the value of a style, i.e. the tt(-t) option only returns a status -(sets tt($?)). Without any var(strings) the return status is zero if the +(sets tt($?)). Without any var(string) the return status is zero if the style is defined for at least one matching pattern, has only one string in its value, and that is equal to one of `tt(true)', `tt(yes)', `tt(on)' or -`tt(1)'. If any var(strings) are given the status is zero if and only if -at least one of the var(strings) is equal to at least one of the strings +`tt(1)'. If any var(string)s are given the status is zero if and only if +at least one of the var(string)s is equal to at least one of the strings in the value. If the style is defined but doesn't match, the return status is tt(1). If the style is not defined, the status is tt(2). @@ -115,12 +115,12 @@ var(pattern) matches at least one of the strings in the value. enditem() ) findex(zformat) -xitem(tt(zformat -f) var(param) var(format) var(specs) ...) -item(tt(zformat -a) var(array) var(sep) var(specs) ...)( +xitem(tt(zformat -f) var(param) var(format) var(spec) ...) +item(tt(zformat -a) var(array) var(sep) var(spec) ...)( This builtin provides two different forms of formatting. The first form is selected with the tt(-f) option. In this case the var(format) string will be modified by replacing sequences starting with a percent -sign in it with strings from the var(specs). Each var(spec) should be +sign in it with strings from the var(spec)s. Each var(spec) should be of the form `var(char)tt(:)var(string)' which will cause every appearance of the sequence `tt(%)var(char)' in var(format) to be replaced by the var(string). The `tt(%)' sequence may also contain optional @@ -132,7 +132,7 @@ width makes the result be padded with spaces to the right if the var(string) is shorter than the requested width. Padding to the left can be achieved by giving a negative minimum field width. If a maximum field width is specified, the var(string) will be truncated after that -many characters. After all `tt(%)' sequences for the given var(specs) +many characters. After all `tt(%)' sequences for the given var(spec)s have been processed, the resulting string is stored in the parameter var(param). @@ -162,7 +162,7 @@ specifier tt(c) is 3, agreeing with the digit argument to the ternary expression. The second form, using the tt(-a) option, can be used for aligning -strings. Here, the var(specs) are of the form +strings. Here, the var(spec)s are of the form `var(left)tt(:)var(right)' where `var(left)' and `var(right)' are arbitrary strings. These strings are modified by replacing the colons by the var(sep) string and padding the var(left) strings with spaces @@ -179,7 +179,7 @@ item(tt(zregexparse))( This implements some internals of the tt(_regex_arguments) function. ) findex(zparseopts) -item(tt(zparseopts) [ tt(-D) ] [ tt(-K) ] [ tt(-M) ] [ tt(-E) ] [ tt(-a) var(array) ] [ tt(-A) var(assoc) ] var(specs))( +item(tt(zparseopts) [ tt(-DKME) ] [ tt(-a) var(array) ] [ tt(-A) var(assoc) ] var(spec) ...)( This builtin simplifies the parsing of options in positional parameters, i.e. the set of arguments given by tt($*). Each var(spec) describes one option and must be of the form `var(opt)[tt(=)var(array)]'. If an option @@ -191,7 +191,7 @@ Note that it is an error to give any var(spec) without an `tt(=)var(array)' unless one of the tt(-a) or tt(-A) options is used. Unless the tt(-E) option is given, parsing stops at the first string -that isn't described by one of the var(specs). Even with tt(-E), +that isn't described by one of the var(spec)s. Even with tt(-E), parsing always stops at a positional parameter equal to `tt(-)' or `tt(-)tt(-)'. @@ -247,14 +247,14 @@ as the values. item(tt(-D))( If this option is given, all options found are removed from the positional parameters of the calling shell or shell function, up to but not including -any not described by the var(specs). This is similar to using the tt(shift) +any not described by the var(spec)s. This is similar to using the tt(shift) builtin. ) item(tt(-K))( With this option, the arrays specified with the tt(-a) option and with the -`tt(=)var(array)' forms are kept unchanged when none of the var(specs) for +`tt(=)var(array)' forms are kept unchanged when none of the var(spec)s for them is used. Otherwise the entire array is replaced when any of the -var(specs) is used. Individual elements of associative arrays specified +var(spec)s is used. Individual elements of associative arrays specified with the tt(-A) option are preserved by tt(-K). This allows assignment of default values to arrays before calling tt(zparseopts). ) -- 1.9.5 (Apple Git-50.3)