1. ValueFormat:Test "NUM1" OPR "num2"["Num1" OPR "num2"]OPR Value:Equality:-EQUnequal:-neGreater than:-GTLess than:-lt "L is the lowercase letter L"Less than equals:-leGreater than or equal to:-ge2. StringFormat:[Str1 OPR str2][OPR str]OPR
Background:There is a source package that contains many subdirectories and makefile, and the packed package is too large to be deleted and then packaged by all the binaries created by make.Demand:Therefore, make clean is required to clear all the
Default variable for Shell script ($ ...)We know that directives can have options and parameters, such as Ls-la to see all properties and permissions that contain hidden files. So can shell script have parameters behind the script file name? It's
Today I learned to write a shell script, a little excited, hereby recorded (actually not difficult to write it)Reason:Now do the projects that require multiple engineering dependencies, but the trouble is that there is no automatic association of
$MYSTR ="node=slave-01:2.05:1.25:1.00"$ time tmp=${mystr%%:*}; echo ${tmp##*=}real 0m0.000suser 0m0.000ssys 0m0.000sslave-${string#*pattern} minimizes matching pattern from the left and deletes (starting from the left) the first pattern
Combat 1: Enter 2 integers to determine the sizeThree ways to achieve:1 defining a variable 2 script parameter 3 read read-inThe first step, give the user prompt, let it enter an integerThe second step is to determine that the first value and the
Below is the output information of my wlan0 NIC, you can use Ifconfig or Ifconfig | Sed-n '/wlan0/,10p ' gets the format of the displayed informationwlan0 Link encap:ethernet hwaddr xx:xx:xx:xx:xx:xx inet addr:172.29.164.251 bcast:
After the user logs on to Linux, a system prompt symbol appears, which allows you to enter a lot of commands after the symbol and get the desired effect, who is behind the scenes who is helping us with this whole pile of things? is the shell, and
Ls-lat list all the stuff in the current directoryLs-lath people look at the sizeLs-f | grep "/$" only DirectoryLS-LR include subdirectories ...LS--ignore filename-lt ignores a Which, in the path specified by the path variable, searches to see if a
1. #注释作用, #! Except in addition, in the parameter replacement echo ${path#*:} here does not represent the comment, the numeral conversion, does not represent the comment echo $ ((2#101011)) 2. Command line delimiter, you can write multiple commands
such as script scripts.sh1. Create a new shellAdd statement at the beginning of the scripts file: #!/bin/sh, via ./scripts.sh(requires execute permission) or sh scripts.sh(no execute permission required)2. Do not create a new shell, execute commands
1. Practice Yourself#!/bin/basha=0while:d o a= ' expr $a + 1 ' if [$a-lt 4]then echo-n-E "input number 1 to 9 \ n" read Num case $Num in 1|2|3|4|5|6 |7|8| 9) Echo-e "You are number is: $Num!" ;; *) echo "R error number, game over!" break;;
One, for loop The For loop works by taking the serial element one by one out, putting it into the specified variable sequentially, and repeating the contained command area (between do and done) until all the elements takeUntil the end. Where serial
The application SP will have the requirements of registered funds, the whole network to reach 10 million, the net to reach a minimum of 1 million of registered capital, all need to be Chinese holding enterprises. Frequently asked questions about
Shell disrupt file lines
The idea is to generate a random array, and then output the row in the file according to the array elements. 1. It is very easy to generate a random array. It was a little difficult to start using it for the first time. The
Shell breaks down file lines,
The idea is to generate a random array, and then output the row in the file according to the array elements. 1. It is very easy to generate a random array. It was a little difficult to start using it for the first time.
The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion;
products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the
content of the page makes you feel confusing, please write us an email, we will handle the problem
within 5 days after receiving your email.
If you find any instances of plagiarism from the community, please send an email to:
info-contact@alibabacloud.com
and provide relevant evidence. A staff member will contact you within 5 working days.
A Free Trial That Lets You Build Big!
Start building with 50+ products and up to 12 months usage for Elastic Compute Service