文章列表
 
您正在查看 "Linux" 分类下的文章

2009年05月25日 星期一 上午 5:32
wc
wc [options] [files]
word count. count the number of words in the specified files, print to stdin number of lines, words and bytes . if no file specified, will read from stdin, until reach EOF(crtl+D is EOF in UNIX, but ctrl+Z in windows) then do the word count.
options:
-c byte count, count the number of bytes,
-m character count,
-l   line count,
-w word count
tail
tail [options]. [files]
print last 10 lines of each file, if no file is
 
2009年05月25日 星期一 上午 5:12
pipe is a way of redirecting stuff from a command to another one without saving it on the disks, very handy if you want to redirect stuff in a single line:
examples:
$ du | sort -n
the vertical bar in between du(disk usage) and sort takes stdout of du, and send it to stdin of sort.
you can use as many pipes in a line as you want.
$ du | sort -rn | more
send du's output to sort, sort it numerically and reverse the order, than send it to more to display one page-full a
 
2009年02月17日 星期二 下午 5:36
the ">" can send a command's output to a file,(if the file exists,it would be overwrited,else will be created)
ls /usr/bin > binaries   the output of ls went in to the file binaries;

>> append the output to the end of file.

> only redirect the "stdout", but not "stderr"
&> or >& will send both stdout and stderr
2> send stderr only


commands are some executable files in some spec
 
2009年02月17日 星期二 下午 5:13
pwd   print working directory, takes no other option

cd [directory(full name)] go to another directory
cd    'cd' with argument return us to our home directory,if your username is abc,it will return to /home/abc

mkdir [directory name]    make a new directory in the current directory.

cd [directory] go in to directory in the current directory
cd ..   return to the directory just above the current one
 
 
   
 
 
文章分类
 
 
 
 
 
 
 
 
 
Cet(1)
 
Usaco(124)
 
 
Vijos(12)
 
 
 
Noip(44)
 
Pku(127)
 
Ural(4)
 
Uva(3)
 
Hdu(12)
 
 
Tju(1)
 
Zoj(1)
 
   
 
文章存档
 
     
 
最新文章评论
  

好厉害
 

此文已拜读欢迎寒舍小聚!!
 

送你一轮月亮, 让你洁白无暇 ;
 

怎么能这么做…… 你真秒杀了吗……怀疑第二问错掉……
 

[表情]
   
帮助中心 | 空间客服 | 投诉中心 | 空间协议
©2012 Baidu