执行脚本

1.

  bash/sh 相对路径、绝对路径

2.

  直接执行:

    先加上权限: chmod +x scripts/hello.sh

    之后直接执行。 scripts/hello.sh(有别的写法)     //使用频率高

    用source或者(. )命令 :  scoure(. ) hello.sh  

 

(source和. 是shell内嵌的)。

  

posted @ 2022-07-05 20:51  zhangdudu  阅读(224)  评论(0)    收藏  举报