摘要: 参考: https://zhuanlan.zhihu.com/p/289274320(shell常用数据结构) https://www.runoob.com/linux/linux-shell-array.html(shell数组) 基本 Shell是弱类型的语言 没有向C、java那样的强类型变量 阅读全文
posted @ 2021-09-28 19:37 小匡程序员 阅读(804) 评论(0) 推荐(0) 编辑
摘要: 参考: https://www.runoob.com/linux/linux-shell-include-file.html(文件包含) https://www.runoob.com/linux/linux-shell-io-redirections.html(输入输出) 文件包含 语法 . fil 阅读全文
posted @ 2021-09-28 19:34 小匡程序员 阅读(85) 评论(0) 推荐(0) 编辑
摘要: 参考 https://www.runoob.com/linux/linux-shell-variable.html(shell变量) 基本知识 1,Shell是弱类型的语言, 没有向C、java那样的强类型变量,都是弱类型变量。都会统一存储为字符串类型。 2,语法 your_name="runoob 阅读全文
posted @ 2021-09-28 19:32 小匡程序员 阅读(159) 评论(0) 推荐(0) 编辑
摘要: 1,变量$含义 使用与shell脚本和shell函数 变量含义 $0 当前脚本的文件名 $n 传递给脚本或函数的参数。n 是一个数字,a56爆大奖在线娱乐第几个参数。例如,第一个参数是$1,第二个参数是$2。 $# 传递给脚本或函数的参数个数。 $* 传递给脚本或函数的所有参数。 $@ 传递给脚本或函数的所有参数。 阅读全文
posted @ 2021-09-28 19:07 小匡程序员 阅读(189) 评论(0) 推荐(0) 编辑
摘要: 参考: https://blog.csdn.net/wzj_110/article/details/86669426(for in 用法总结) 循环for in,基于列表 语法: for 变量名 in 列表 do command command ... done 数字类循环 1,seq在in后面的应 阅读全文
posted @ 2021-09-28 18:39 小匡程序员 阅读(309) 评论(0) 推荐(0) 编辑