Skip to content

Instantly share code, notes, and snippets.

@c0ldlimit
Last active August 29, 2015 14:05
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save c0ldlimit/6228e8d63dc34c71a552 to your computer and use it in GitHub Desktop.
Save c0ldlimit/6228e8d63dc34c71a552 to your computer and use it in GitHub Desktop.
#linux commands cheatsheet
# copy an entire directory
cp -R dirtocopy/ newdir/
# view the last modified file in a directory
less $(ls -t *.out | head -1)
# redirection
# http://superuser.com/questions/480599/with-regards-to-piping-commands-what-are-the-greater-than-and-less-than
# http://en.wikipedia.org/wiki/Redirection_%28computing%29
> "output to"
>> "append to"
< "input from"
| "pipe"
#http://stackoverflow.com/a/11856575
nohup node server.js > /dev/null 2>&1 &
# http://stackoverflow.com/a/11856575
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment