The first scenario: do use multiple devices or simulatorsWorkaround: (Specify a device or emulator to connect to)1. Get the simulator/device list
adb devices
2. Specify device to execute ADB shell
Section III: The wording of conditional judgmentIf conditional judgment, the "conditional judgment" in the grammatical structure of if can have many forms. The test result is true, just to see if it returns a value of 0.The following 10 types of
Arithmetic operations in the shell require no spaces between numbers and operators;Special symbols do not need to be escaped;If the arithmetic expression contains other variables, you do not need to use the $ reference;General arithmetic operations:+
Managing Shell JobsWhen moving jobs between the foreground and background, it could be useful to a overview of all current jobs. To get such a overview, use the jobs command. As can see in Table 9.2, this command gives an overview of all jobs
One, shell condition Test man bash//view HelpCommands for conditional testsTest option file name or directory nameOr[option file name or directory name]Cases:[-E/ETC/PASSD]File status-F//judgment is not a file, is the file is True- D//Determine if
Entry
Awk and Bourne shell are the basis of POSIX shell
In addition to the POSIX standard, there are European x/open standards
Two types of regular expressions
BRE basic Regular Expressions basic grep use
ERE
In the recent work, the product group of colleagues to give the data are all lowercase letters, but the engine team colleagues asked them to get from the data inside the structure of the analysis is all capitalized structure, which makes our data
Examples are as follows: Batch create 10 random string of files, require each file name after adding _aaa, suffix name unchanged;[[email protected] goodboy]# lsadddbbdedf.html baacjaiija.html bhcfaabcfh.html dgjdcdfbca.html efejadfdji.htmlagdhcdeaje.
This article is sponsored by Ilanniweb, starting in Slime Line the worldWant to get more articles, you can follow my ilanniwebThe company's business is to use Tomcat as a Web container, in order to more effectively utilize server performance, we
In the process of writing shell scripts, we often customize some functions and execute the corresponding process according to the function's return value, so how do we get the return value of the function?There are two ways to call a function in the
Let's review the usage of the last section redirect:1. Quickly empty filesCat Demo.txt Note: Linux has a classic saying "Everything is a file",/dev/null can be considered a special empty file, more image point, can be understood as a sci-fi film in
There are two ways you can execute shell scripts under Linux:1, execute the script with Shell program: According to the type of your shell script, choose shell Program, commonly have sh,bash,tcsh etc. (generally the first line #!/bin/bash indicates
The shell is a programming language, a command interpreter, which is the kernel that interprets the commands we enter.He is divided into two types, the interactive mode is that the shell waits for your input, and executes the commands you submit;
The simple thing is to write some shell syntax and commands in it, plus regular expressions, pipeline commands, and data flow redirection to achieve the purpose we want.Shell scripts is a good tool for system administration, but it is not fast
Variable Description: $$ the PID of the shell itself (ProcessID) $! PID of the Shell's last running background process $? end code of the last Run command (return value) $- flag at a glance using the SET command $* all parameter
#! /bin/sh#shell script takes care of starting and stopping# The GlassFish DAS and GlassFish instance.## Chkconfig:-64 36# Description:tomcat Auto Start#/ETC/INIT.D/TOMCATD# Tomcat Auto-start# Source function library.#. /etc/init.d/functions# source
Determine how long the Linux file has been modified to perform actionsCreate a scriptvi/var/tomcat/find.sh#!/bin/bashA= ' stat-c%y/var/tomcat/logs/catalina.out ' //Get File modification time (in seconds)b= ' Date +%s ' //time to get the current
Tag: Shell variable command executes the variable as a commandThe shell will execute the variable when the command executes "multiple commands simultaneously execute the problem"Today, a shell script is written that requires variables to be run as
This note is for the early ximo of the shelling Basic video tutorial, organized notes. The tools used in this note:http://download.csdn.net/detail/obuyiseng/9466056Introduction:the FSG shell is a compression shell. We use 9 ways of shelling
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