On Thursday 04 May 2006 11:37, Paul Jarc wrote:
> Mike Frysinger <[EMAIL PROTECTED]> wrote:
> > On Thursday 04 May 2006 00:44, Paul Jarc wrote:
> >> What do you mean by "fail"? What do you want to happen in this case?
> >
> > i meant gawk hates it ... not bash
>
> Ok, and what about the second que
Mike Frysinger <[EMAIL PROTECTED]> wrote:
> On Thursday 04 May 2006 00:44, Paul Jarc wrote:
>> What do you mean by "fail"? What do you want to happen in this case?
>
> i meant gawk hates it ... not bash
Ok, and what about the second question? What are you trying to do
that you haven't figured ou
On Thursday 04 May 2006 11:08, Mike Stroyan wrote:
> A little more bash syntax can quote newlines for awk.
this is when you start using gawk -v foo="$foo" ...
i was using gawk as an example of my variable expansion question, not as a way
to figure out how to pass a variable into gawk
-mike
___
A little more bash syntax can quote newlines for awk.
$ foo="a
b
c"
$ lf="
"
$ gawk 'BEGIN {foo="'"${foo//$lf/\\n}"'"} END {print foo}' /dev/null
a
b
c
--
Mike Stroyan
[EMAIL PROTECTED]
___
Bug-bash mailing list
Bug-bash@gnu.org
http://lists.gnu.org/
On Thursday 04 May 2006 00:44, Paul Jarc wrote:
> Mike Frysinger <[EMAIL PROTECTED]> wrote:
> > $ foo="a b c"
> > $ gawk 'BEGIN {foo="'${foo}'"}'
> > gawk: BEGIN {foo="a
> > gawk:^ unterminated string
>
> This is normal. man bash:
>
> # Word Splitting
> # The shell scans the
Mike Frysinger <[EMAIL PROTECTED]> wrote:
> $ foo="a b c"
> $ gawk 'BEGIN {foo="'${foo}'"}'
> gawk: BEGIN {foo="a
> gawk:^ unterminated string
This is normal. man bash:
# Word Splitting
# The shell scans the results of parameter expansion, command substitu-
# tion, an
ignoring the fact that i can pass in variables to gawk using the '-v' option,
i'm wondering if this is a bug in how bash expands variables to pass to
programs ... i couldnt pick out anything under EXPANSION, but that's probably
just because i missed it ;)
take for example:
$ foo="a b c"
$ gawk