shell
文章平均质量分 62
bash shell使用笔记
555路过555
这个作者很懒,什么都没留下…
展开
-
shell脚本判断一个命令是否存在
文章目录1. 直接执行2. 内建命令POSIX compatible:For Bash specific environments:3. 外部工具参考1. 直接执行优点:简单、直接。缺点:会启动程序,对于rm 、python等命令需要加上没有其它副作用的参数。如查看版本的参数–version。# 方法1ls &> /dev/nullif [ $? -eq 0 ]then echo "exist"fi# 方法2if python --version &> /原创 2021-04-09 15:06:50 · 1118 阅读 · 0 评论 -
How To Find your Server's Public IP Address
If you do not know what your server’s public IP address is, there are a number of ways you can find it. Usually, this is the address you use to connect to your server through SSH.From the command li...转载 2018-07-16 13:45:31 · 422 阅读 · 0 评论