OLD | NEW |
1 # Atom | 1 # Atom |
2 | 2 |
3 [TOC] | 3 [TOC] |
4 | 4 |
5 ## Workflow | 5 ## Workflow |
6 | 6 |
7 A typical Atom workflow consists of the following. | 7 A typical Atom workflow consists of the following. |
8 | 8 |
9 1. Use `Ctrl-Shift-R` to find a symbol in the `.tags` file or `Ctrl-P` to find | 9 1. Use `Ctrl-Shift-R` to find a symbol in the `.tags` file or `Ctrl-P` to find |
10 a file by name. | 10 a file by name. |
11 2. Switch between the header and the source using `Alt-O`. | 11 2. Switch between the header and the source using `Alt-O`(`Ctrl-Opt-S` on OSX). |
12 3. While editing, `you-complete-me` package helps with C++ auto-completion and | 12 3. While editing, `you-complete-me` package helps with C++ auto-completion and |
13 shows compile errors through `lint` package. | 13 shows compile errors through `lint` package. |
14 4. Press `Ctrl-Shift-P` and type `format<Enter>` to format the code. | 14 4. Press `Ctrl-Shift-P` and type `format<Enter>` to format the code. |
15 5. Select the target to build by pressing `F7` and typing, for example, | 15 5. Select the target to build by pressing `F7` and typing, for example, |
16 `base_unittests`. | 16 `base_unittests`. |
17 6. Rebuild again by pressing `F9`. | 17 6. Rebuild again by pressing `F9`. |
18 | 18 |
19 ## Atom packages | 19 ## Atom packages |
20 | 20 |
21 To setup this workflow, install Atom packages for Chrome development. | 21 To setup this workflow, install Atom packages for Chrome development. |
22 | 22 |
23 ``` | 23 ``` |
24 $ apm install build-ninja clang-format \ | 24 $ apm install build-ninja clang-format \ |
25 linter linter-eslint switch-header-source you-complete-me | 25 linter linter-cpplint linter-eslint switch-header-source you-complete-me |
26 ``` | 26 ``` |
27 | 27 |
28 ## Autocomplete | 28 ## Autocomplete |
29 | 29 |
30 Install C++ auto-completion engine. | 30 Install C++ auto-completion engine. |
31 | 31 |
32 ``` | 32 ``` |
33 $ git clone https://github.com/Valloric/ycmd.git ~/.ycmd | 33 $ git clone https://github.com/Valloric/ycmd.git ~/.ycmd |
34 $ cd ~/.ycmd | 34 $ cd ~/.ycmd |
35 $ ./build.py --clang-completer | 35 $ ./build.py --clang-completer |
(...skipping 85 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
121 on a project that frequently uses `foo` or `bar` in files names, you can create | 121 on a project that frequently uses `foo` or `bar` in files names, you can create |
122 a small `.tags` file to efficiently search the symbols within these files. Be | 122 a small `.tags` file to efficiently search the symbols within these files. Be |
123 sure to use "Exuberant Ctags." | 123 sure to use "Exuberant Ctags." |
124 | 124 |
125 ``` | 125 ``` |
126 $ git ls | egrep -i "foo|bar" | ctags -f .tags -L - | 126 $ git ls | egrep -i "foo|bar" | ctags -f .tags -L - |
127 ``` | 127 ``` |
128 | 128 |
129 Don't create a ctags file for the full Chrome repository, as that would result | 129 Don't create a ctags file for the full Chrome repository, as that would result |
130 in ~9GB tag file that will not be usable in Atom. | 130 in ~9GB tag file that will not be usable in Atom. |
OLD | NEW |