Bash variable Category:
Local variable: Also called local variable, valid only for the current shell process
Environment variables: current shell and its child shell, child shell ....
Special variables: $? The status of the last
Vii. Process Control conditional judgment control in bash Scripts [] (the expression in [] is true) && (the result of the front is true when executing the command behind) | | (The result of the front is false when executing the command behind)
A PHP common data type
1. Basic data types
1.1 Integral type1.2 Decimal type (floating number) contains single precision and double precision1.3 Boolean types (representation True, and false)1.4 String
2. Composite data type
2.1 Arrays (Array)2.2
1.2 Terminal printing
A terminal is an interactive tool that allows users to interact with the shell environment. Printing text in a terminal is a basic task that most shell scripts and tools need to perform daily. Through the terminal
Gawk is a modified awk by the GNU organization, which has a very good application on the Linux operating system and does not require compiling, more than other languages more concise, highly efficient, and able to interact with the shell, is one of
1. Linux Scripting Basics
1.1 Basic Introduction to grammar
1.1.1 Start
The program must start with the following line (must be on the first line of the file):
#!/bin/sh
The symbolic #! is used to tell the system that the parameters behind it
Shell Getting Started Tutorial: Shell variables
Variable
A variable is a place to store data temporarily, and is a memory space. Bash shell and other programming languages, there is no "data form", which means that the default is not to
Problems with visitor pattern resolution
In our code writing process, we often need to add some code to some similar objects, we take a computer object printing components as an example to look at:
/**
* Abstract class unit
{
/**
The TR (translate abbreviation) is used primarily to remove control characters from files or to convert characters.
Syntax: TR [–c/d/s/t] [SET1] [SET2] #SET1: Character Set 1;set2: Character Set 2-c:complement, replace the characters except SET1
Using MVC in PHP has become increasingly popular, especially in some open source frameworks. MVC is enough to deal with most situations, but there are some things that are not appropriate, such as simple personal blog, for only hundreds of article
1 Create a simple hello.c by dockerfile and then do a simple docker image
, this is base image, the base image of the shared host
Create directories, such as the HelloWorld directory, create dockerfile files, write
From scratch
ADD
Copy Code code as follows:
/*************by garcon1986*********/
The difference between print and Echo:
1. Echo can enter multiple strings, and print cannot.
print "Hello". " World "; Success
The echo "Hello". World "; Success
Print "Hello"
The cut command reads content from a file or standard input and intercepts specific portions of each row and sends it to standard output.
There are three kinds of interception, one is by character position, the other is by byte position, three is
1, LS: Similar to the DOS under the dir command
LS The most commonly used parameter has three:-a-l-F.
Ls–a
Files on Linux are treated as hidden files by the system, with the LS command is not visible to them, and with ls-a in addition to
Substitution is what.
Shell when it encounters an expression that contains one or more special characters for substitution. Example:
The following example enables printing to replace the value of the variable with its value. and "" is a new line to
one echo command output text
1.1 displaying normal strings
echo [Options] string
option means that the command option, only-n, does not output a newline character at the end of the line.
If the text you want to output is made up of multiple
a function
There is no obvious difference between a function and a shell script, but there is an essential difference in execution:
for a separate shell script, create a new shell process for it when executing, and interpret and execute the code in
1. Signal ProcessingLinux uses signals to communicate with processes running in the system.Signal Value Description1 SIGHUP Suspend process2 SIGINT Terminate Process3 Sigquit Stop Process9 SIGKILL Unconditional Termination processSIGTERM terminate
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.