Monday, 12 August 2013

How do I remove the carriage return from an echo on Solaris?

Solaris "echo" doesn't know about the -n switch, try it and see:

# echo -n test
-n test
#

To get the right behaviour you need "\c", which you use like this:

# echo "test \c"
test #

No comments:

Post a Comment