Configuration Information [Automatically generated, do not change]:
Machine: x86_64
OS: darwin15.6.0
Compiler: clang
Compilation CFLAGS: -DPROGRAM='bash' -DCONF_HOSTTYPE='x86_64' -DCONF_OSTYPE='d\
arwin15.6.0' -DCONF_MACHTYPE='x86_64-apple-darwin15.6.0' -DCONF_VENDOR='apple' \
-DLOCALEDIR='/usr/local/Cellar/bash/4.4/share/locale' -DPACKAGE='bash' -DSHELL \
-DHAVE_CONFIG_H -DMACOSX -I. -I. -I./include -I./lib -I./lib/intl -I/private\
/tmp/bash-20160915-5981-sovv96/bash-4.4/lib/intl -DSSH_SOURCE_BASHRC -Wno-pare\
ntheses -Wno-format-security
uname output: Darwin Normans-MacBook-Pro.local 15.6.0 Darwin Kernel Version 15.\
6.0: Mon Aug 29 20:21:34 PDT 2016; root:xnu-3248.60.11~1/RELEASE_X86_64 x86_64
Machine Type: x86_64-apple-darwin15.6.0
Bash Version: 4.4
Patch Level: 0
Release Status: release
Description:
I was playing around with the new --help feature and I was expecting it should work for all commands at the interactive prompt. The local command did not work that way. Can exceptions be made for the local command?
$ local --help
bash44: local: can only be used in a function
$ f() {
> local --help
> }
$ f
local: local [option] name[=value] ...
Define local variables.
Create a local variable called NAME, and give it VALUE. OPTION can
be any option accepted by `declare'.
Local variables can only be used within a function; they are visible
only to the function where they are defined and its children.
Exit Status:
Returns success unless an invalid option is supplied, a variable
assignment error occurs, or the shell is not executing a function.