摘要: 阅读全文
posted @ 2014-04-06 20:34 M.Bing 阅读(219) 评论(0) 推荐(0) 编辑
摘要: 【转载】Linux Shell 中的反引号,单引号,双引号反引号位 (`) 位于键盘的Tab键的上方、1键的左方。注意与单引号(')位于Enter键的左方的区别。 在Linux中起着命令替换的作用。命令替换是指shell能够将一个命令的标准输出插在一个命令行中任何位置。 如下,shell会执行反引号中的date命令,把结果插入到echo命令显示的内容中。 [root@localhost sh]# echo The date is `date` The date is 2011年 03月 14日 星期一 21:15:43 CST 单引号、双引号用于用户把带有空格的字符串赋值给变量事... 阅读全文
posted @ 2014-04-06 20:30 M.Bing 阅读(181) 评论(0) 推荐(0) 编辑
摘要: 1 shell 的$! ,$?, $$,$@$n $1 the first parameter,$2 the second...$# The number of command-line parameters.$0 The name of current program.$? Last command or function's return value.$$ The program's PID.$! Last program's PID.$@ Save all the parameters.almost any shell book will tal... 阅读全文
posted @ 2014-04-06 20:21 M.Bing 阅读(536) 评论(0) 推荐(0) 编辑