Who commandThe WHO command is to display the user information of the current login system, execute the WHO command to know which users are currently logged into the system, execute the WHO command separately to list the login account, the terminal
WedgeRecently like the script so learn a little bit and solidify yourself.Simple Log emptying note! This is a test environment that can be emptied freely.Cd/var/logCat/dev/null>messagesecho "Logs cleaned up."One, can vim a file name example
(a) accept an input, judging is not a date, the user's input can be 2017-10-1 or 2017.10.1 or 2017/10/1The shell code is as follows#!/bin/bashRead-p "Input:" DateA= ' echo $date | Awk-f ' [./-] ' {print $ '/' $ '/' $ $} 'Date-d $a &>/dev/nullIf
Case 1: variables, functions, judgments, comparisonstest.sh[JavaScript]View PlainCopy
#!/bin/bash
Echo ======================== This is a bash demo========================
printf "%s is%d years old \ n" Zhengjinwei
DECLARE count=10
How to quickly write a startup script , mainly through the following several1, logical smoothing
can be in TXT file, have pseudo code way, form system, List order, then add code in a little bit
Determine if the program is running
The shell generates 100 6-bit random numbers in a number of ways:Here's a script that reads:650) this.width=650; "Src=" https://s2.51cto.com/wyfs02/M00/06/AF/wKiom1m8Ax-wV92tAAA8Jft99zI996.jpg-wh_500x0-wm_ 3-wmp_4-s_3612996601.jpg "title="
See other people's study summary, feel good turn over (transfer from tryfly)First, Shell Script FoundationThe shell script is a program written using the shell's function, which uses a plain text file, writes some shell syntax and instructions
2017 the latest enterprise face Test shell (iv)First, the draw script (1) requires the following:1, write a script execution, enter the name, generate a random number 01-99 between the number;2, after entering the name, the screen output information,
Shell The technique of text slicing inIn the shell there is also a string slice this thing exists, has been used in Python slices, the following record the use of slices in the shell.(1) , replacing some of the text in the variable contents$var = "
2017 the latest enterprise face Test Shell (ii)Exercise 1: write a shell script that lists the IP of the 192.169.5.0/24 network segment online. (Locate the active IP)Requirements are as follows:1. The online IP and the online IP are placed in two
Original link: http://www.361way.com/shell-eval-variable/4957.htmlNesting of variables is often used in the shell. For example, the value of a single or multiple variables as a variable name, and then the variable name to get its internal variables,
We can pass parameters to the script when executing the Shell script, and the format of the parameters obtained in the script is:$n. n represents a number, 1 is the first argument to execute the script, 2 is the second argument to execute the script,
I. What is a script (scripts)A command file that installs a logical relationship record, in which the file name can be used to initiate the execution of a command within a script, and the shell script is an explanatory language that requires an
The specific meaning of the prompt can be consulted: http://billie66.github.io/TLCL/book/zh/chap14.htmlUbuntu16.04 personal configuration as follows, for later review1 functionGit_branch {2branch= "' Git branch 2>/dev/null | grep "^\*" | Sed-e "s/^\*
650) this.width=650; "src=" Https://s3.51cto.com/wyfs02/M00/9E/D1/wKioL1mWuEXjPgg_AADSEroFgqw866.png "title=" Shell programming--$ The meaning of the number. png "alt=" Wkiol1mwuexjpgg_aadserofgqw866.png "/> $* Same as the general directive,
Put a bunch of commands in the script into executable script execution;Script, file name is. SH, get hostname host nameSystem variables:ENV: View System VariablesSet: All variables can be printed with grep andExport path: Define Global variables
You unity3d developers, you also for your code is anti-compilation headache, confusion and encryption has been invalidated, for memory dump code and worry? Is the hard-to-make game a problem of piracy being copied? Is it feared that the algorithm
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