From 8530a4bd9e5c4da1596f85654b92c4e316932281 Mon Sep 17 00:00:00 2001 From: Delapouite Date: Sun, 1 Mar 2020 13:43:14 +0100 Subject: [PATCH] =?UTF-8?q?doc:=20add=20interlinks=20between=20`echo`=20?= =?UTF-8?q?=E2=86=90=E2=86=92=20`printf`=20commands?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- doc_src/cmds/echo.rst | 9 +++++---- doc_src/cmds/printf.rst | 9 +++++---- 2 files changed, 10 insertions(+), 8 deletions(-) diff --git a/doc_src/cmds/echo.rst b/doc_src/cmds/echo.rst index 6f8d82d19..71f1f3818 100644 --- a/doc_src/cmds/echo.rst +++ b/doc_src/cmds/echo.rst @@ -57,18 +57,19 @@ If ``-e`` is used, the following sequences are recognized: Example ------- - - :: echo 'Hello World' Print hello world to stdout - - :: echo -e 'Top\\nBottom' Print Top and Bottom on separate lines, using an escape sequence + +See Also +-------- + +- the :ref:`printf ` command, for more control over output formatting diff --git a/doc_src/cmds/printf.rst b/doc_src/cmds/printf.rst index b6d82b369..ca56c4bb3 100644 --- a/doc_src/cmds/printf.rst +++ b/doc_src/cmds/printf.rst @@ -66,18 +66,19 @@ This file has been imported from the printf in GNU Coreutils version 6.9. If you Example ------- - - :: printf '%s\\t%s\\n' flounder fish Will print "flounder fish" (separated with a tab character), followed by a newline character. This is useful for writing completions, as fish expects completion scripts to output the option followed by the description, separated with a tab character. - - :: printf '%s: %d' "Number of bananas in my pocket" 42 Will print "Number of bananas in my pocket: 42", _without_ a newline. + +See Also +-------- + +- the :ref:`echo ` command, for simpler output