关于shell for循环具体详细说明可参考:http://wiki.jikexueyuan.com/project/linux-command/chap34.html example: 分别在community develop lenovo zte这4个目录下创建x86_64.i386两个子目录 for dir in community develop lenovo zte; do mkdir $dir/x86_64, mkdir $dir/i386; done…
centos shell脚本编程2 if 判断 case判断 shell脚本中的循环 for while shell中的函数 break continue test 命令 第三十六节课 return用在函数中exit用在shell当中 直接退出整个脚本,整个子shell或当前shellbreak退出循环 上半节课 if 判断case判断shell脚本中的循环 下半节课 for whileshell中的函数breakcontinue 课程大纲(继续上节课的) 7. if…
写出 shell 脚本中所有循环语法 for 循环 : for i in $(ls);do echo item:$i done while 循环 : #!/bin/bash COUNTER=0 while [ $COUNTER -lt 10 ]; do echo The counter is $COUNTER let COUNTER=COUNTER+1 done until 循环 : #!/bin/bash COUNTER=20 until [ $COUNTER -lt 10 ]; do ech…