Skip to content

Instantly share code, notes, and snippets.

@brianpeiris
Last active February 6, 2021 07:23
Show Gist options
  • Save brianpeiris/6165618 to your computer and use it in GitHub Desktop.
Save brianpeiris/6165618 to your computer and use it in GitHub Desktop.
Bash Cheatsheet
# Because I always forget this stuff
# Run a command in the background with its output redirected
<command> > /dev/null 2>&1 &
# A while loop
while true; do
echo 'hi';
sleep 1;
done
# On one line
while true; do echo 'hi'; sleep 1; done
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment