Bash Script: Problem running variable command containing ""
I need to run the following command inside a bash script:
Code:
dialog --backtitle "Back Title" --title "Title" --menu "" 40 40 10 \ But when i run it it will be ran as: Code:
dialog --backtitle "Back Title" --title "Title" --menu "" 40 40 10 \ Code:
var1="1" Code:
var="$var $var1 $var2" Code:
var="$var \"${var1}\" \"${var2}\"" Code:
var=$(echo $var \"$var1\" \"$var2\") This is a little hard to explain, but you can download the script from http://62.73.217.42/paasan.tar.gz It will extract itself to a directory called "paasan" containing the script and a modified version of dialog. Really hope someone can help Thanks in advance :) |
Ok, I've downloaded the script, but I still do not understand what the problem is. It looks like the command generated is exactly as you posted it in the first code block. Post an example of what you are seeing and what you'd expect to see.
|
This is what it looks like:
http://62.73.217.42/2.jpg This is what i want it to look like: http://62.73.217.42/1.jpg |
All times are GMT -5. The time now is 03:50 PM. |