Answers for "bash dev/null"

1

bash dev/null

Anything sent to /dev/null will be automatically discarded. 
This is useful if we dont care about the output of a command (just that it ran).

$  grep -r hello /sys/ > /dev/null 2>&1

- discarding stdout with first >
- discarding stderr with second 2>
Posted by: Guest on October-03-2021

Browse Popular Code Answers by Language