POSIX shell tips
This article is used to record some of the useful tips I have found. This is a paper about POSIX (and other noncompliant shell script techniques. I have always insisted that the Bourne system is not a good programming language,
In this chapter we'll look at a seemingly trivial detail-our shell. This examination would reveal some of the inner working of the shell and the terminal emulator program itself.Many things in linux,the shell prompt was highly configurable,and while
Shell:An interface program that completes interactive operations between the user and the operating system, providing users with simplified operations; In the 70 's mid-century in Bell Labs, Bourne bit UNIX developed a shell program Bourne Shell,
Recall a thing: Before using Linux to find Chinese input method, in Baidu entered the FCITX, and then the result has a, you are looking for is not: satirical Tencent. Originally can not remember this input method name, but later brother remember
$ CD ' DirName $ ' and some special usages of pwd%/* shell variables in the command line state simply execute $ CD ' DirName $ ' is meaningless. Because he returns the "." of the current path.This command, written in a script file, returns the
It is meaningless to simply execute $ CD 'dirname $ 0' in the command line state. Because it returns "." of the current path ".".
This command works only when it is written in a script file. It returns the directory where the script file is stored
One, the basic Bash Shell command 1, the default bash shell prompt is the dollar sign ($); 2. The Bash manual uses the man command to access the manual pages stored on the Linux system, such as:
Bogon:~ mac$ man Kill
KILL (1) BSD
Version 1.0, refer to some articles on the web to be structured. Later intends to continue to revise. Complete a shell development specification that suits you.Last modified: 2017.6.25I. Naming specification 1, version and operating parameters1)
1.1 Shell some small summary1, 0 wide assertion 2, Print menu 3, getopts option Introduction 4, script query IP geolocation1.1.1 grep zero-width Assertions (0 wide assertion)It means taking out what you want and getting rid of things you don't care
Standard I/O Library
The standard I/O Library and its header files provide a 10 thousand interface called by the underlying I/O system. this library is not part of ANSI Standard C, and the system call we mentioned earlier is not. However, this
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.