摘要: [root@pxc3 ~]# vi function8.sh#!/bin/bashtext="global variable"tj=91850use_local_var_fun(){ local text="local variable" echo "In function use_local_va 阅读全文
posted @ 2021-08-25 15:48 beawh 阅读(223) 评论(0) 推荐(0) 编辑
摘要: #!/bin/bashshow_week(){ for day in Monday Tuesday Wednesday Thursday Friday Saturday Sunday do echo "$day " done} show_number(){ for (( i = 1; i <= 7; 阅读全文
posted @ 2021-08-25 14:43 beawh 阅读(32) 评论(0) 推荐(0) 编辑
摘要: #! /bin/bashparameter=ind_argind_arg=Helloind_func(){ echo "$1"}ind_fun(){ echo "test!!!"}ind_func "$1"ind_func "$parameter"ind_func "${!parameter}"in 阅读全文
posted @ 2021-08-25 11:15 beawh 阅读(42) 评论(0) 推荐(0) 编辑