It is not matter of "best way", but the "easiest way". But as you put the question like that, I would like to mention that [tt]echo[/tt] is a shell built-in function while [tt]cat[/tt] is an executable. That means that [tt]echo[/tt] should be faster, while [tt]cat[/tt] should be more portable between shells.
Code:
[blue]master #[/blue] type echo
echo is a shell builtin
[blue]master #[/blue] type cat
cat is /usr/bin/cat
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.