Gentoo Archives: gentoo-user

From: Pandu Poluan <pandu@××××××.info>
To: gentoo-user@l.g.o
Subject: Re: [gentoo-user] [OT] bash script error
Date: Mon, 09 May 2011 08:35:01
Message-Id: BANLkTin16kj4HcyJL3LooX3HxCvs5qvJkA@mail.gmail.com
In Reply to: Re: [gentoo-user] [OT] bash script error by Xi Shen
1 (Forgive my top-posting)
2
3 try:
4
5 curl_opts="-x \'\'"
6
7 Rgds,
8
9
10 On 2011-05-09, Xi Shen <davidshen84@××××××××××.com> wrote:
11 > yes, i use the '-x' option, and i can see the expansion now. and i
12 > found there are too many quotes.
13 >
14 > i tried curl_opts=-x "", does not work.
15 >
16 >
17 > On Mon, May 9, 2011 at 3:52 PM, Kfir Lavi <lavi.kfir@×××××.com> wrote:
18 >>
19 >>
20 >> On Mon, May 9, 2011 at 9:43 AM, Nils Andresen <nils@×××××××××××××.de>
21 >> wrote:
22 >>>
23 >>> Hi,
24 >>> have you tried "/bin/bash -x your.script.sh" - see what get's expanded ?
25 >>>
26 >>> Nils
27 >>>
28 >>> 2011/5/9 Xi Shen <davidshen84@××××××××××.com>
29 >>>>
30 >>>> I guess there's something wrong with the argument expansion. Just do
31 >>>> not know how to fix it. Please help.
32 >>>>
33 >> You need to change:
34 >> - curl_opts="-x ''"
35 >> + curl_opts=-x ""
36 >>
37 >> Run your program with bash -x as Nils said, and you will see the
38 >> expansion.
39 >>
40 >> Kfir
41 >>
42 >
43 >
44 >
45 > --
46 > Best Regards,
47 > Xi Shen (David)
48 >
49 > http://twitter.com/davidshen84/
50 >
51 >
52
53
54 --
55 --
56 Pandu E Poluan - IT Optimizer
57 My website: http://pandu.poluan.info/