linux-sh

1、文件必须以 #!/bin/sh 开头

符号#!用来告诉系统后面是执行文件的程序。

2、注释:以#开头

3、变量:所有变量都是字符串,不需要申明变量的类型

eg:a="hello world!"

引用变量两种:$a 、${a}

4、环境变量:export

5、常用unix命令

echo "hello!" 打印在屏幕

ls:文件列表

wc:word count

cp:

mv:

rm:

grep 'searchstring' filename:搜索

 

posted @ 2017-11-30 14:21  海东青Lo  阅读(213)  评论(0)    收藏  举报