Fix typo and tweak set docs

Move the docs for the `-n` flag to `set` out of the list of scopes.
This commit is contained in:
Kevin Ballard 2014-07-12 00:21:04 -07:00
parent 98297e5234
commit 8c89e6bce5
2 changed files with 2 additions and 2 deletions

View file

@ -519,7 +519,7 @@ static int builtin_set(parser_t &parser, wchar_t **argv)
} }
/* We can't both list and erase varaibles */ /* We can't both list and erase variables */
if (erase && list) if (erase && list)
{ {
append_format(stderr_buffer, append_format(stderr_buffer,

View file

@ -27,13 +27,13 @@ The following options control variable scope:
- <code>-l</code> or <code>--local</code> forces the specified shell variable to be given a scope that is local to the current block, even if a variable with the given name exists and is non-local - <code>-l</code> or <code>--local</code> forces the specified shell variable to be given a scope that is local to the current block, even if a variable with the given name exists and is non-local
- <code>-g</code> or <code>--global</code> causes the specified shell variable to be given a global scope. Non-global variables disappear when the block they belong to ends - <code>-g</code> or <code>--global</code> causes the specified shell variable to be given a global scope. Non-global variables disappear when the block they belong to ends
- <code>-U</code> or <code>--universal</code> causes the specified shell variable to be given a universal scope. If this option is supplied, the variable will be shared between all the current users fish instances on the current computer, and will be preserved across restarts of the shell. - <code>-U</code> or <code>--universal</code> causes the specified shell variable to be given a universal scope. If this option is supplied, the variable will be shared between all the current users fish instances on the current computer, and will be preserved across restarts of the shell.
- <code>-n</code> or <code>--names</code> List only the names of all defined variables, not their value
- <code>-x</code> or <code>--export</code> causes the specified shell variable to be exported to child processes (making it an "environment variable") - <code>-x</code> or <code>--export</code> causes the specified shell variable to be exported to child processes (making it an "environment variable")
- <code>-u</code> or <code>--unexport</code> causes the specified shell variable to NOT be exported to child processes - <code>-u</code> or <code>--unexport</code> causes the specified shell variable to NOT be exported to child processes
The following options are available: The following options are available:
- <code>-e</code> or <code>--erase</code> causes the specified shell variable to be erased - <code>-e</code> or <code>--erase</code> causes the specified shell variable to be erased
- <code>-q</code> or <code>--query</code> test if the specified variable names are defined. Does not output anything, but the builtins exit status is the number of variables specified that were not defined. - <code>-q</code> or <code>--query</code> test if the specified variable names are defined. Does not output anything, but the builtins exit status is the number of variables specified that were not defined.
- <code>-n</code> or <code>--names</code> List only the names of all defined variables, not their value
- <code>-L</code> or <code>--long</code> do not abbreviate long values when printing set variables - <code>-L</code> or <code>--long</code> do not abbreviate long values when printing set variables
If a variable is set to more than one value, the variable will be an If a variable is set to more than one value, the variable will be an