![](https://img-blog.csdnimg.cn/20201014180756925.png?x-oss-process=image/resize,m_fixed,h_64,w_64)
shell
wolves_liu
一起学习
展开
-
[ shell ] — if、for、while、utile、case、break、continue、函数、重定向——3
一、条件语句a=10b=20#ifif [ $a == $b ]then echo "两数相等" fi写成一行:if [ $a != $b ]; then echo "两数不相等"; fi#if elseif [ $a == $b ]then echo "两数相等" else echo "两数不等" fi#if else-if elsei...原创 2019-10-29 17:17:59 · 173 阅读 · 0 评论 -
[ shell ] — 注释、运算符、echo、printf、test——2
一、Shell注释1.1.单行注释 #开头的行,就会被注释#--------------------------------------------# 这是一个注释# author:wolves_liu# site:www.wolves_liu.com# slogan:学的不仅是技术,更是梦想!#--------------------------------------------...原创 2019-10-29 16:56:05 · 251 阅读 · 0 评论 -
[ shell ] — 基础、变量、字符串、数组——1
shell脚本,第一句: #!/bin/sh 或者 #!/bin/bash#!是告诉系统用bash来运行shell脚本命名:name或者name.sh, 后缀.sh更直观,说明这是一个shell脚本文件运行方法:bash test.sh 或者 source test.sh 或者 . test.sh 或者 /bin/sh test.sh 或者 /bin/bash test.sh一、sh...原创 2019-10-29 16:24:11 · 165 阅读 · 0 评论