首页 诗词 字典 板报 句子 名言 友答 励志 学校 网站地图
当前位置: 首页 > 教程频道 > 操作系统 > UNIXLINUX >

Linux Shell Select&Case第四行报错解决办法

2013-01-23 
Linux Shell Select&Case第四行报错本帖最后由 LightUpHeaven 于 2013-01-12 21:15:07 编辑#!/bin/bash#aa

Linux Shell Select&Case第四行报错
本帖最后由 LightUpHeaven 于 2013-01-12 21:15:07 编辑 #!/bin/bash
#aa.3
select mychoice in  size information cfiles exit
do
case $mychoice in
size) ls -s;;
information) ls -l;;
cfiles) ls *.c;;
exit) exit 0;;
esac
done
运行bash aa.3
错误:
'a.3: line 4: syntax error near unexpected token `in
'a.3: line 4: `case $mychoice in
     shell linux
[解决办法]
恭喜,接分。
[解决办法]
原脚本的第四行多加了`

热点排行