解决 shell 脚本:/bin/sh^M: bad interpreter
2011-11-01 09:45
447 查看
#sh>vi filename
利用如下命令查看文件格式
:set ff 或 :set fileformat
可以看到如下信息
fileformat=dos 或 fileformat=unix
利用如下命令修改文件格式
:set ff=unix 或 :set fileformat=unix
:wq (存盘退出)
本文出自 “专注HA架构集群” 博客,请务必保留此出处http://jafy00.blog.51cto.com/2594646/702830
利用如下命令查看文件格式
:set ff 或 :set fileformat
可以看到如下信息
fileformat=dos 或 fileformat=unix
利用如下命令修改文件格式
:set ff=unix 或 :set fileformat=unix
:wq (存盘退出)
本文出自 “专注HA架构集群” 博客,请务必保留此出处http://jafy00.blog.51cto.com/2594646/702830
相关文章推荐
- Ubuntu学习总结-08 Ubuntu运行Shell脚本报 shell /bin/bash^M: bad interpreter错误问题解决
- sh脚本异常,binsh^M bad interpreter No such file or directory
- sh脚本异常:/bin/sh^M:bad interpreter
- shell脚本报错 /bin/bash^M: bad interpreter
- shell脚本中报 “/bin/sh^M: bad interpreter: 没有那个文件或目录”解决方法
- 关于shell脚本中报 “/bin/sh^M: bad interpreter: 没有那个文件或目录”的解决方法
- Shell脚本bash: ./t.sh:/bin/bash^M:损坏的解释器: 没有那个文件或目录
- Shell脚本bash: ./t.sh:/bin/bash^M:损坏的解释器: 没有那个文件或目录
- shell脚本:Syntax error: Bad for loop variable错误解决方法
- shell脚本异常“bash: ./rebuild.sh: /bin/sh^M: bad interpreter: No such file or directory
- FreeBSD上Enter full pathname of shell or RETURN for /bin/sh 问题的解决
- 运行shell脚本,错误bash: ./temp.sh: /bin/bash^M: bad interpreter: No such file or directory
- linux shell编程:/bin/bash^M bad interpreter:没有那个文件或目录解决方法
- shell脚本异常“bash: ./rebuild.sh: /bin/sh^M: bad interpreter: No such file or directory”
- shell脚本报错:-bash: xxx: /bin/sh^M: bad interpreter: No such file or directory
- shell脚本报错:-bash: xxx: /bin/sh^M: bad interpreter: No such file or directory
- shell脚本异常:/bin/sh^M:bad interpreter: No such file or directory
- shell脚本:/bin/sh^M: bad interpreter: No such file or directory
- -bin-sh-m-bad-interpreter-no-such-file-or-directory