新建shell脚本
vim test.sh
在脚本中编写执行语句
#! /bin/bash
mysql -ubrell -pbrell <<EOF
USE test;
SELECT * FROM test;
EOF
赋予test.sh执行权限并运行脚本
chmod +x test.sh
./test.sh
博客介绍了shell脚本的操作流程,包括新建shell脚本,在脚本中编写执行语句,最后赋予test.sh执行权限并运行该脚本,属于信息技术中后端开发相关内容。
新建shell脚本
vim test.sh
在脚本中编写执行语句
#! /bin/bash
mysql -ubrell -pbrell <<EOF
USE test;
SELECT * FROM test;
EOF
赋予test.sh执行权限并运行脚本
chmod +x test.sh
./test.sh
3018
3832
7353

被折叠的 条评论
为什么被折叠?