'!/bin/sh -e'行是做什么的? [英] What does the line '!/bin/sh -e' do?

查看:165
本文介绍了'!/bin/sh -e'行是做什么的?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

在服务器(linux)上文件的开头(位于/etc/init.d/文件夹中),我有以下一行:

In the beginning of a file on my server (linux), which is located in the /etc/init.d/ folder I have this line:

 !/bin/sh -e

这是什么意思,因为每次执行脚本的其余部分时,它都会正常运行,但显示以下错误除外:

What does it mean, because every time I execute the rest of the script it works fine except for an error which shows:

 !/bin/sh not found

有什么想法吗?

推荐答案

在我看来像是一团糟

Looks to me like a messed up shebang line. You need to put a '#' in front of the '!'.

这篇关于'!/bin/sh -e'行是做什么的?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆