linux怎么执行脚本

linux怎么执行脚本

linux怎么执行脚本?

首先脚本需要有执行权限:chmod u x file.sh;

方法:

用shell程序执行脚本:根据你的shell脚本的类型,选择shell程序,常用的有sh,bash,tcsh等;

然后输入命令:

bash myshell.sh

(其中bash为shell的名称,myshell.sh则为你要执行的代码)

推荐:《Linux教程

以上就是

© 版权声明
THE END
喜欢就支持一下吧
点赞12 分享