Re: Bash commands
Russell wrote:
>
> Hi,
>
> When i try a command like:
>
> debpc:# if [ -n df /mnt | grep -ie "/dev/hdc1" ] echo "yes"
>
> then after i press "return", i get a command prompt ">" which
> seems to be waiting for more input. Why does that happen?
sorry, i missed out some things. I think the promp > happens when
the statement is unfinished (no "fi"). Should be:
debpc:# if [ -n df /mnt | grep -ie "/dev/hdc1" ] ; then echo "yes" ; fi
However, this gives the error:
[: missing ']'
grep: ]: No such file or directory
Reply to: