Foreword
Why do we despise GUI programmers TT
With the growing development of IT technology, the popularity of various visualization tools for the majority of programmers provide a lot of convenience, especially as a graphical front-end engineers are sensitive to color, naturally, on the graphical user interface put it down. but in the back-end, operation and maintenance and other traditional command-line programmer crackling knock the fly, always feel they have been deeply despised, because they are glass heart, and do not want to live in the underlying contempt chain, so they tinker at the command line, in order toAfter going in front of white loading forceAs a programmer improve their basic literacy
BASH
Speaking of the command line, mac, it certainly can not be separated terminal. Mac ternimal default of a bash, the default project path is / users / drx (your username)
What is bash?
bash / zsh, and so it is a shell script of c language interpreter, the shell script used to compile interpreted into machine instructions, so that we can send commands to the machine through scripting, we want to perform operating.
P.s: Loading forceNiubi great God likes to tinker with a thing called zsh, in fact, and also as a bash shell script interpreter, but it has a variety of powerful plug-ins to extend its functionality, such as a variety of topics pleasing, can simplify your command line operation, etc. As to how to replace bash zsh, please move to how to install oh my zsh with the MAC , Windows users should find another expert.
PATH
Speaking bash, it will certainly involve PATH
PATH is a series of catalog value, which determines the bash will go to the directory in which to find a command or program. When you run a program, Linux compiler and linker to search in these directories. For example, after you install npm global, should the npm add the path in the pATH to run npm command in bash
Common Linux commands
Linux command is too much, and as a front-end programmers, many of which are out of reach.
But the goal is the full stack engineer you, is commonly used Linux commands must master.
If nothing else, do not knock instruction Ali himself with a cloud server can be put forward to death.
so do not limit yourself to the yo
ls
ls
ls -l //显示目录的详细信息
Used to obtain a directory listing of the current path
pwd
pwd
Full name used to get the current path
cd
cd ../
cd ./
cd ~/
cd path
Change the current path to a path
chomd
sudo chmod 777 -r xxx
The xxx file in the current directory / folder permissions changed to read-write
touch
touch xx.js
Creating xx.js file in the current path
we
vi xx.js
Xx.js open the file in the current directory with the vi editor
Enter the edit mode: i
Exit edit mode: esc
Enter the command mode: :
:w(保存)
:q(退出)
:wq(保存并推出)
mkdir
mrdir xx
Xx created called in the current path空文件夹
rm
rm -rf xx
Xx delete the current path of the file / folder
r : recursive
f : force
cp
cp -r xx path
The xx file / folder to the path path
mv
mv xx path (yy)
The file path xx file / folder path to move to the next path, and rename yy
if the path parameter is not written, is functionally equivalent to rename the file
without yy write parameter, is functionally equivalent to moving files
Epilogue
Hope that their future can practice makes perfect, to encourage each other's.
This article is reproduced in: Ape 2048 https://www.mk2048.com/blog/blog.php?id=hh2iici1kcb