[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Arithmetic expansion with increments and output redirection
From: |
Chet Ramey |
Subject: |
Re: Arithmetic expansion with increments and output redirection |
Date: |
Wed, 24 Apr 2019 09:11:12 -0400 |
User-agent: |
Mozilla/5.0 (Macintosh; Intel Mac OS X 10.14; rv:60.0) Gecko/20100101 Thunderbird/60.6.1 |
On 4/23/19 5:49 PM, Ian Neal wrote:
> Bash Version: 4.2
> Patch Level: 46
> Release Status: release
>
> Description:
> When using arithmetic expansion with variable pre- and
> post-increments/decrements in the output redirection file path,
> specifically on external executables (not builtins or functions), the state
> of the variable being incremented/decremented is not persisted in the
> environment.
The redirection is expanded in the environment of the command. In the
second case, that means the child process forked to run /bin/true.
--
``The lyf so short, the craft so long to lerne.'' - Chaucer
``Ars longa, vita brevis'' - Hippocrates
Chet Ramey, UTech, CWRU chet@case.edu http://tiswww.cwru.edu/~chet/
- Re: Arithmetic expansion with increments and output redirection, (continued)
- Re: Arithmetic expansion with increments and output redirection, Chet Ramey, 2019/04/24
- Re: Arithmetic expansion with increments and output redirection, Ian Neal, 2019/04/24
- Re: Arithmetic expansion with increments and output redirection, Chet Ramey, 2019/04/24
- Re: Arithmetic expansion with increments and output redirection, Ilkka Virta, 2019/04/24
- Re: Arithmetic expansion with increments and output redirection, Chet Ramey, 2019/04/24
- Re: Arithmetic expansion with increments and output redirection, Greg Wooledge, 2019/04/24
- Re: Arithmetic expansion with increments and output redirection, Ian Neal, 2019/04/24
- Re: Arithmetic expansion with increments and output redirection, Chet Ramey, 2019/04/24
Re: Arithmetic expansion with increments and output redirection,
Chet Ramey <=