Search Results

Search: Posts Made By: Justin Alvarez
6,584
Posted By Justin Alvarez
Firstly, thanks for the replies, guys.. i...
Firstly, thanks for the replies, guys.. i appreciate the help.

ilikecows: yes, changed it to #!/bin/bash but makes no difference.

kshji: I need to use the read -r option so that it interprets...
6,584
Posted By Justin Alvarez
#!/bin/sh read -rp "Command to execute: "...
#!/bin/sh
read -rp "Command to execute: " the_command
echo "$the_command"
eval "$the_command"
Here's what happens:

but now i enter the command as echo "cat" but realise it's supposed to be...
6,584
Posted By Justin Alvarez
BASH Shell script - help with read
Hi all,

I'm sure this is quite a simple problem, but i'm completely new to shell scripting, so bare with me. Having problems with the read command. Here's what I have:

read -rp "Command to...
Showing results 1 to 3 of 3

 
All times are GMT -4. The time now is 04:21 AM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy