1. FindFind Pathname-options [-print-exec-ok]Let's take a look at the parameters of the command:Pathname the directory path found by the Find command. For example, use. To represent the current directory, and/to represent the system root
ZZ: http://doc.linuxpk.com/80440.html
Sed (Stream Editor) usage:
1. It is a non-interactive text stream editor. It edits a file or copies the text exported from standard input.
2. Specify the text line to be changed using the row number or
HTC hero mobile phone players have become a habit and pleasure in trying to brush different ROM systems, but we can also try to brush the shell with different colors, you can change the color of your phone at will. Recently, a player on the modaco
AIX shell skills
1) command completion and history command function: set-o vi and then use (ESC \) to complete the file name in the command, use (ESC +) to view the historical command list, and use (ESC -) use the previous command.
You can use esc
Principle: awk command, split formatted txt (txt file format separated by "|") into an array, and then splice it into HTML format (HTML-head-title-body-table)
Shell Source Code
#! /Bin/shfile_input0000'txt.log'file_output0000'txt2html.html
After the release of the iPhone 5 yesterday, it did not bring the wireless charging technology that everyone was looking forward to, so it is still necessary to continue to use the charger honestly. There is a disadvantage in charging with charging
Suppose there is a log-XXX1, A log-XXX2, A log-XXX3 .... but because the development board space is limited, you need to control the number of files to 3, and keep the latest one, so you want to write a script to execute some operations at each
A simple ShellProgram
Let's look at a shell program.
-----------------
#! /Bin/sh # this is to show what a example looks like. echo "our first example" Echo # This inserts an empty line in outputecho "we are currently in the following
This problem was discovered when the SGE startmpi. Sh script was transformed. Consider the following shell code:
Code highlighting produced by Actipro CodeHighlighter (freeware)http://www.CodeHighlighter.com/-->#! /Bin/sh
# Declare-I
Testline =
I have studied a problem "[Erlang 0050] using fun to write tail recursion in Erlang shell" and have been paying attention to this problem. Recently, I found the same problem in search engines, the question is clear enough. Calling fun () from fun ()
As a non-programmer and software quality control personnel, the most common task in daily work is to conduct software quality testing. During software quality testing, you need to frequently set up a test environment, configure test tools, run test
In day-to-day shell work, History commands are edited, just like command line editing. As mentioned above, software quality testing faces a large number of complex system environments and involves a lot of complex work in these system environments.
From the programmer's perspective, shell itself is a program written in C language. From the user's perspective, shell is a bridge between the user and the Linux operating system. You can enter commands for execution and use shell script programming
This is the first phase of the shell Learning Series and will be constantly updated...
Specific Learning books: Unix shell programming (Third edition)
This section describes some tools that are frequently used in shell programming.
1. Shell tool --
Process Control
In Bash Shell, there are two main types of Flow Control commands: Selection and loop. The options include: if, case; for, while, and until. The select command is both select and loop. Either way, a conditional test is required, and
For Loop example
For Loop Syntax:
for VARIABLE in 1 2 3 4 5 .. Ndo command1 command2 commandNdone #!/bin/bashfor i in 1 2 3 4 5doecho "Welcome $i times"doneBash version 3.0 +Version#!/bin/bash for i in {1..5}do echo
I. First, let's look at the following in linux:
Copy codeThe Code is as follows :#! /Bin/bash
Cd/ftp/
CURRENTDATE = 'date + % Y % m % d'
YESTERDAY = 'date-d yesterday + % Y % m % d'
THREEDAYAGO = 'date-d' 3 days ago '+ % Y % m % d'
# Echo $
Use the here document
Copy codeThe Code is as follows :#! /Bin/sh
Ftp-ivn 210.29.28.124 User yun yun2011
LCD/home/veyun
Cd/home/veyun/yhb
Get v
Bye
EOF
Explanation:
-I: Disable interaction prompts during multi-file transmission, so there
Mycommand> mylog.txt 2> & 1 should be the most classic usage.
Command results can be output in the form of "%>", % indicates the file descriptor: 1 indicates the standard output stdout, and 2 indicates the standard error stderr. The default value of
EMACS
If Bash finds that the value of this variable is 'T' in the environment when the shell is started, it considers that the shell runs in the Emacs shell Buffer and does not allow row editing.
ENV
Similar to BASH_ENV, it is used in shell
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.