On 8/24/17 9:49 PM, L A Walsh wrote:

> However, in testing posix and non-posix modesĀ  in bash 4.4.12, I don't
> see aliases being enabled in scripts.
> 
> To be POSIX conformant, wouldn't they have to be on?

They are:

$ ../bash-4.4-patched/bash --version
GNU bash, version 4.4.12(4)-release (x86_64-apple-darwin15.6.0)
Copyright (C) 2016 Free Software Foundation, Inc.
License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html>

This is free software; you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law.
$ cat x6
set -o posix
alias lf='echo lf'
lf
$ ../bash-4.4-patched/bash ./x6
lf
$ ../bash-4.4-patched/sh ./x6
lf
$ cat x6a
alias lf='echo lf'
lf
$ ../bash-4.4-patched/bash -o posix ./x6a
lf
$ ../bash-4.4-patched/sh ./x6a
lf



-- 
``The lyf so short, the craft so long to lerne.'' - Chaucer
                 ``Ars longa, vita brevis'' - Hippocrates
Chet Ramey, UTech, CWRU    c...@case.edu    http://cnswww.cns.cwru.edu/~chet/

Reply via email to