解决shell脚本错误$’r’ command not found
2020-01-14 05:47
477 查看
从windows上传了一个脚本到Linux上执行 出现如下错误:$'\r': command not found
这是windows与Unix文本编辑的默认格式不同造成的,需要转成unix格式。
[root@localhost ~]# yum install -y Example.sh [root@localhost ~]# dos2unix Example.sh dos2unix: converting file Example.sh to Unix format ...
转载于:https://my.oschina.net/xiangyunyan/blog/3069033
- 点赞
- 收藏
- 分享
- 文章举报
相关文章推荐
- shell脚本中的bash错误:$'\r': command not found [caca]
- MySQL shell脚本执行错误 $'\r':command not found
- shell 脚本 “bc: command not found ” 解决
- shell脚本执行错误 $'\r':command not found
- shell 脚本 “bc: command not found ” 解决
- ubuntu终端执行shell脚本报command not found解决方法
- shell脚本if语法错误:if[ 20 == 10 ]: command not found
- linux系统中shell中执行命令是报:bash: ifconfig: command not found错误的解决办法
- Shell 脚本中 command not found 错误
- shell脚本执行错误 $'\r':command not found
- 解决内核编译时产生 "mkimage" command not found - U-Boot images will not be built 错误
- ubuntu 14.04 编译android4.0 出现gcc-version.sh: line 11: cc: command not found错误解决方法
- bash: groupadd: command not found 错误解决[转]
- 解决mysql shell执行中文表名报command not found错误
- Root路径设置错误,命令不能找到,command not found 的解决办法
- linux环境变量 shell变量 command not found解决方法
- 安装NDK:Cygwin中出现-bash: $'\r': command not found 错误 的解决办法
- Linux下的-bash: command not found错误(解决方法)
- Linux 出现-bash: grunt: command not found 错误解决
- bash: service: command not found 错误的解决方法