Why do you choose to use Atom
Atom is a GitHub-launched editor, known as the 21st century hack editor, which features modern, easy-to-use, customizable.
I've used a variety of editors before, and now I'm going to summarize my personal views on each editor:
Vim is the editor that I use the longest and the longest time to toss.
Its advantages are forced lattice high, strong customization, editing efficiency, low resource consumption, but also terminal operation
The disadvantage is that the learning curve is steep, often out of some inexplicable error, suddenly is a bunch of debugging information flashed, the most ugly, even if the use of a variety of plug-in landscaping, or the most ugly.
In addition to its own modernization features too little, too dependent on plug-ins, if you want to achieve the most basic functions of the IDE, need to install a lot of plug-ins, the quality of the plug-in itself and mutual compatibility is also a problem.
The advantage of Emacs is that it is powerful and can be realized, because he is an operating system.
The disadvantage was that the entry threshold was high, and I learned two books about Emacs and Lisp in order to use Emacs. But I personally think its biggest problem is that the accelerator is too anti-human, especially in the notebook when the fingers really unbearable ...
Sublimetext
Very beautiful, at least when it was just out of the most beautiful editor, with some editor should have some features, so do not need to configure how to get started.
The disadvantage is closed source, charge, VIM mode of the cursor is too ugly, the Chinese support is not good, have been out of Linux for several years or even Chinese are not able to fight out (although some methods can be resolved, but to a certain extent can explain the author's attitude towards Chinese users, which is a closed source reflects a problem).
Vscode
Microsoft launched the editor, the previous period of time just open source, and feel like atom. This is the editor I am very optimistic about, but now the issue is the release time is too short, the function and plug-in is not rich enough, the biosphere has not yet formed, perhaps another two years to rule the world.
Atom with the above editor advantage is more balanced, easy to use, 0 threshold, resource consumption is not high, the function of its own support is quite many, configuration is also very convenient, there is a large number of plug-ins can choose, but also open source free, and in the support of Chinese also no problem.
This tutorial mainly refer to Atom's Official document 1.7.4 version, the tutorial used in many of the pictures are also taken from there, in the following article will not be noted.
The shortcut keys mentioned in the following article will be in the form of Mac, in general, Mac cmd
keys correspond to the win and Linux Ctrl
, the ctrl
keys correspond to win and Linux Alt
, please convert the reader, the text will not repeat.
Installation
Open the official homepage
The Web page will automatically determine your operating system and give its corresponding download button
For example, my system is a Mac, you can click Download For Mac
the button to download the system corresponding to the installation package
If you want to download the installation package for another system, click the Other platforms
link
Mac
After extracting the downloaded ZIP installation package, drag the extracted Atom
app to the app directory
or install via homebrew cask
brew cask install atom
Windows
Run the installation package installation
Linux
If it is a Debian-based distribution, execute the command:
sudo dpkg -i atom-amd64.deb
If it is Redhat, then execute:
rpm -i atom.x86_64.rpm
When the installation is complete, run atom and you will see an interface that shows that we have successfully installed
Basic Use Command panel
Atom has learned and referenced the features of the previous excellent editor in many places, one of which is the command panel.
When you saw it for the first time, you thought you were using sublime.
The command panel is one of the most common features in Atom, and when you use shortcut keys in the editor Cmd+Shift+P
, you'll see it
All commands defined in Atom and plug-ins can be entered in the Control Panel, and fuzzy search is supported
For example, when you enter Cboo, all commands that contain these 4 characters are listed.
The shortcut keys for this command, if any, are also displayed after the commands listed.
Setup window
The self-visualizing setup interface is one of the most convenient reasons for atom to be used, rather than having to manually modify the configuration file, as the traditional editor does.
You can use the following three ways to open the Settings window
1. Main Menu Edit
Preferences
2. Enter the command in the command panel Settings View:Open
. Because the command window supports fuzzy queries, you just need to enter svo
it.
3. Using shortcut keysCmd+,
In the Settings window you can set up and manage various editor behaviors, keyboard shortcuts, plugins, themes, etc.
Set the window interface theme and code highlighting
Atom comes with 4 different window themes and 8 code highlighting methods
Can be configured and modified by setting the Themes page in the window
There are also more than n more than a third-party production of the theme can be installed, the installation method will be described in the following
File Operation Open File
You can File
Open...
open the Cmd+O
File Selection window via the main menu, or by using the shortcut key.
Save File
Main Menu, File
Save
Shortcut keysCmd+S
Save As:Cmd+Shift+S
Save All Files:Cmd+Alt+S
Open Folder
Opening a folder is a useful feature to open a project's root directory like the IDE
You can open or add a directory by selecting the main menu, or you File
Add Project Folder
can use shortcut keys Cmd+Shift+O
.
After you open a folder, all subdirectories and files under that folder are displayed on the left side of the main window as a directory tree, just like
You can a
m
delete
create new, rename, delete, and so on files by right-clicking the menu in the tree bar or by using the shortcut key when you select a file.
If you want to toggle the display and hide of the tree bar, you can use the shortcut key Cmd+\
or the commandTree View:Toggle
In the directory tree, the right-click menu can also implement the file copy and paste functions.
Find Files
When you open one or more directories, you can:
* Cmd+T
Cmd+P
search for files in the directory by or
* Cmd+B
Search for a file that is currently open by
* Cmd+Shift+B
search for a new or changed file
Of course, these features also support fuzzy queries
If you need to filter out certain files (such as. pyc files) or directories when searching (for example,. Git), can be configured core.ignoredNames
and fuzzy-finder.ignoredNames
.
You can also core.excludeVcsIgnoredPaths
filter out the files configured in. gitignore by configuring them.
The specific configuration method will be discussed later.
Summarize
In this article we learned how to install atom and some basic methods of use, after learning this part of the content to believe that you can already easily use atom
In later lessons we will learn some of the more advanced uses of atom, making it easier and smoother to use.
Atom Editor Getting Started to master (i) Installation and Usage basics