|
| From: | Chandler |
| Subject: | Re: [EXT]Re: Suddenly, periods / dots in variable values are converted to space |
| Date: | Mon, 23 Jan 2023 21:36:05 -0700 |
| User-agent: | Mozilla/5.0 (X11; Linux x86_64; rv:102.0) Gecko/20100101 Firefox/102.0 Thunderbird/102.6.0 |
Greg Wooledge wrote on 1/23/23 5:44 PM:
localized to a single command, as in:
IFS=. read -ra myarray ...
or in a function:
join() { local IFS="$1"; shift; printf '%s\n' "$*"; }
Yes that's what I figured, but, can it be both, without local? It was
something like this:
join() {
IFS=. read -ra myarray ...
...
}
Yet for some reason IFS was persisting. Fortunately, it was unneeded and I
figured a way to do the same thing without IFS.
| [Prev in Thread] | Current Thread | [Next in Thread] |