linux shell 编程
SHELL编程一、Shell语法1.1、变量声明1.2、数组声明和使用1.3、特殊的变量1.4、运算和运算符1.4.1、整数运算符1.5、流程语句1.5.1、if 语句1.5.2、case语句1.5.3、select 语句1.6、循环语句1.6.1、for语句1.6.2、while 语句1.6.3、breake 和continue1.6.4、shift三、shell程序调试四、信号五、bash中常用的命令[@more@]SHELL编程一、Shell语法1.1、变量声明变量=值 (注意:等号两侧不能有空格) a=”hello”b=9unset a 撤销变量 areadonly a=2 声明静态的变量 a=2 ,不能 unsetexport 变量名 可把变量提升为全局环境变量,可供其他shell