|
Content of Content of a variable!
I got a sample BASH script like this :
$ cat test
MYVAR=$1
DUMMY1="This is tricky"
DUMMY2=24
echo $[$MYVAR]
$ ./test DUMMY1
./test: line 5: This is tricky: syntax error in expression (error token is "is tricky")
**I was expecting the output as "This is tricky", ah! but no luck
**But this works fine for intergers, no issues :-)
$ ./test DUMMY2
24
Could anyone guide me how to get the string in DUMMY1(i.e "This is tricky") through MYVAR? Please
|