February 2012
M T W T F S S
« Apr    
 12345
6789101112
13141516171819
20212223242526
272829  

Shell Scripts: using wc and grep and awk

1. count the code lines using wc.

1: wc -l `find . -name *.c`

2. count the code lines, using an elegant way "xargs" to transfer the arguments of wc

1: find . -name *.c |xargs wc -l

3. count the code lines, self calculation the result of wc using awk

[...]

The Essential of Shell scripts

In Linux world, shell script is a powerful language, maybe it’s not easy, but it’s practical for use.
I have read a lot of scripts in the past, but when asked to write a snippet of script, I usually need to query other’s code for reference.
But today suddenly I find shell script is quite practical and [...]