Standard input (/dev/stdin)

From wikieduonline
Revision as of 11:37, 15 February 2024 by Welcome (talk | contribs) (Welcome moved page Standard input (stdin) to Standard input (/dev/stdin))
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to navigation Jump to search
This article is a Draft. Help us to complete it.

wikipedia:stdin

  • 2>&1
  • &>


https://unix.stackexchange.com/questions/61931/redirect-all-subsequent-commands-stderr-using-exec
#!/bin/bash -

exec > >(tee "$HOME/somefile.log") 2>&1

echo "$HOME"
echo hi
echo "Command to err but will be redirected to stdout" 1>&2
command_that_pipes_output_to_stderr_but_will_be_redirected_to_stdout
echo "End script"

Activities[edit]

Related terms[edit]

See also[edit]

Advertising: