bug-bash
[
Top
][
All Lists
]
Advanced
[
Date Prev
][
Date Next
][
Thread Prev
][
Thread Next
][
Date Index
][
Thread Index
]
IFS as the control variable in a for loop
From
:
Grisha Levit
Subject
:
IFS as the control variable in a for loop
Date
:
Mon, 2 May 2016 15:06:50 -0400
When in a non-interactive shell, IFS, when modified as the control variable in a for loop does not change splitting behavior.
$ bash -c 'for IFS in .; do printf "%s\n" "$IFS" "$*"; done' bash x x
.
x x
$ bash -ic 'for IFS in .; do printf "%s\n" "$IFS" "$*"; done' bash x x
.
x.x
reply via email to
[Prev in Thread]
Current Thread
[
Next in Thread
]
IFS as the control variable in a for loop
,
Grisha Levit
<=
Re: IFS as the control variable in a for loop
,
Chet Ramey
,
2016/05/08
Prev by Date:
Re: param expansion with single-character special vars in the environment
Next by Date:
Re: param expansion with single-character special vars in the environment
Previous by thread:
Re: declare [-+]n behavior on existing (chained) namerefs
Next by thread:
Re: IFS as the control variable in a for loop
Index(es):
Date
Thread