1
0
Fork 0
mirror of https://github.com/tldr-pages/tldr.git synced 2025-06-05 08:46:15 +02:00
tldr/pages/common/echo.md
2021-03-30 09:54:21 -04:00

24 lines
546 B
Markdown

# echo
> Print given arguments.
> More information: <https://www.gnu.org/software/coreutils/manual/html_node/echo-invocation.html>.
- Print a text message. Note: quotes are optional:
`echo "{{Hello World}}"`
- Print a message with environment variables:
`echo "{{My path is $PATH}}"`
- Print a message without the trailing newline:
`echo -n "{{Hello World}}"`
- Append a message to the file:
`echo "{{Hello World}}" >> {{file.txt}}`
- Enable interpretation of backslash escapes (special characters):
`echo -e "{{Column 1\tColumn 2}}"`