When we need to use escape sequence characters with echo
command we must use the -e
option. Like
echo -e "Enter your name : \c"
But when we include such kind of statements inside a shell program (.sh file), it produces a mysterious error. It prints
-e Enter your name :
It doesn't need that -e
option with echo command as if we write like this
echo "Enter your name : \c"
It shows output with no errors, but that doesn't work in shell.
So what is the reason? I am using bash shell and Ubuntu 15.04 version.