2014-05-11 11:20:51 +01:00
|
|
|
# echo
|
|
|
|
|
2016-01-07 17:31:27 +00:00
|
|
|
> Print given arguments.
|
2014-05-11 11:20:51 +01:00
|
|
|
|
2016-01-07 17:31:27 +00:00
|
|
|
- Print a text message. Note: quotes are optional:
|
2014-05-11 11:20:51 +01:00
|
|
|
|
2014-05-11 12:11:46 +01:00
|
|
|
`echo {{"Hello World"}}`
|
2014-05-11 11:20:51 +01:00
|
|
|
|
2016-01-07 17:31:27 +00:00
|
|
|
- Print a message with environment variables:
|
2014-05-11 11:20:51 +01:00
|
|
|
|
2014-05-11 12:11:46 +01:00
|
|
|
`echo {{"My path is $PATH"}}`
|
2016-07-21 14:52:49 +01:00
|
|
|
|
|
|
|
- Print a message without the trailing newline:
|
|
|
|
|
|
|
|
`echo -n {{"Hello World"}}`
|
|
|
|
|
2019-06-22 16:40:44 +01:00
|
|
|
- Append a message to the file:
|
|
|
|
|
|
|
|
`echo {{"Hello World"}} >> {{file.txt}}`
|
|
|
|
|
2016-07-21 14:52:49 +01:00
|
|
|
- Enable interpretation of backslash escapes (special characters):
|
|
|
|
|
|
|
|
`echo -e {{"Column 1\tColumn 2"}}`
|