Created
October 30, 2013 16:30
-
-
Save pythonicrubyist/7235695 to your computer and use it in GitHub Desktop.
Handy Linux Commands
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
ls *.txt | wc -l | tee /dev/tty count.txt |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
In the above example, the ls command would list all .txt files in the current directory, take a word count (wc) by the amount of lines (-l) and the output displayed to the /dev/tty (terminal) will be sent to the count.txt.