1,323   Linux Shell

1,首先赋权执行

> chmod +x test.sh

2,指定shell类型执行

> /usr/bin/sh test.sh # 使用sh
> /usr/bin/bash test.sh # 使用bash

3,根据文件头部的 #!/bin/sh或者#!/bin/bash

> ./test.sh



Leave a Reply

Your email address will not be published. Required fields are marked *