shell出错test_path: command not found
2016-07-29 10:24
489 查看
1 #!/bin/bash
2
3 test_path = /alidata/myfile
4 echo $(ls $test_path)
5 for i in $(ls $test_path)
6
7 do
8 echo i
9 done
./test.sh
./test.sh: line 3: test_path: command not found
for.sh hello.sh name.sh test.sh www
i
i
i
i
i
自己检查发现变量跟等号中间有个空格,当成了命令
2
3 test_path = /alidata/myfile
4 echo $(ls $test_path)
5 for i in $(ls $test_path)
6
7 do
8 echo i
9 done
./test.sh
./test.sh: line 3: test_path: command not found
for.sh hello.sh name.sh test.sh www
i
i
i
i
i
自己检查发现变量跟等号中间有个空格,当成了命令
相关文章推荐
- Mybatis出错:Property 'Lname' not found on type com.myTest.entity.PerLoc
- cocos2d-x 在android上运行 TestCPP会出错,提示 class not found
- [XCode错误]XCode编译出错异常:ld: framework not found Kernel clang: error: linker command failed with e
- shell脚本中字符串的常见操作及"command not found"报错处理(附源码)
- Linux PATH---ROOT 下arm-linux-gcc command not found
- Mac OS使用技巧之二:修改变量Path解决android: command not found
- TortoiseSVN Show Log 出错:svn/***/!svn/*** path not found
- Linux(centos5.5)中shutdown命令出错:bash: shutdown: command not found
- shell /bin/bash^M: bad interpreter错误和-bash: rz: command not found
- ssh整合是Caused by: java.io.FileNotFoundException: class path resource [bean/test/User.hbm.xml] cannot
- jenkins执行shell命令,有时会提示“Command not found”----处理方案
- java.io.FileNotFoundException: class path resource [bean/test/User.hbm.xml] cannot be opened because it does not exist
- 使用pecl安装php扩展时出错-bash: pecl: command not found
- 9fe2 Jenkins中shell-script执行报错sh: line 2: npm: command not found
- caffe编译 `make pytest` 出错:`fatal error: 'pyconfig.h' file not found`
- shell脚本在cygwin下运行报错: $'\r': command not found
- 解决linux64位安装jpeg 出错make: ./libtool: Command not found
- 安装CocoaPods 出错-bash: $: command not found
- Caused by: java.lang.ClassNotFoundException: android.view.fragment in loader dalvik.system.PathClass
- 使用intellij的svn时提示出错: Can't use Subversion command line client: svn.Errors found while svn working co