SED单行脚本快速参考[同时包含awk实现] 转自:http://sed.sourceforge.net/sed1line_zh-CN.html 和 http://linuxtoy.org/archives/sed-awk.html在以下地址可找到本文档的最新(英文)版本: http://sed.sourceforge.net/sed1line.t
#!/bin/bash #check set -e #install rsync workDir=$PWD installlog=$PWD/install.log # yum install rsync if [ -d /etc/init.d/xinetd ]; t
#/bin/bash yum install vsftpd db4-utils -y if [ `uname -m | grep "x86_64"` ];then X86=1 mv /etc/pam.d/vsf
#!/bin/bash read -p "please input your name" NAME read -p "please input your passwd" PASSWD read -p "please i
脚本是08年的
Linux CentOS Debian Shell脚本的if判断语句条件说明 无论什么编程语言都离不开条件判断。SHELL也不例外。 大体的格式如下: if list then do something here &nbs
######################## ########### [root@qqdserver ~]# awk -F : '$1!~/root/{i=1;while (i<=4) {print $i; i++}}' /etc/passwd bin x 1 1 daemon x 2 2 adm x 3
##################### [root@qqdserver ~]# awk -F : ' {print $1,$7} ' /etc/passwd root /bin/bash bin /sbin/nologin daemon /sbin/nologin adm /sbin/nologin lp /sbin/nologi
shell脚本中一些特殊符号 在shell中常用的特殊符号罗列如下: # ; ;; . , / \\ 'string'| ! $ &n
grep的用法 首先创建我们练习grep命令时需要用到的demo文件demo_file。 $ cat demo_fileTHIS LINE IS THE 1ST UPPER CASE LINE IN THIS FILE.this line is the 1st lower case line in this file.This Line Has All Its First
Copyright © 2005-2024 51CTO.COM 版权所有 京ICP证060544号