Skip to content

Commit 23d8c24

Browse files
authored
Update README.md
1 parent 47af101 commit 23d8c24

File tree

1 file changed

+23
-14
lines changed

1 file changed

+23
-14
lines changed

README.md

Lines changed: 23 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -60,11 +60,11 @@ This Vim plugin is built on top of the great tool [CodeQuery](https://github.com
6060
>
6161
> Main TODO:
6262
> * Use Vim8's new features to enhance usability.
63-
> * Do lazy-loading.
64-
> * Fix some bugs
63+
> * ~~Do lazy-loading.~~
64+
> * Test it.
6565
>
6666
> Completeness: 92%
67-
> v1.0 Release Date: Mid-September
67+
> Current Version: v0.8
6868
>
6969
> It is Ok to try it! 👌
7070
@@ -78,11 +78,10 @@ echo mkdir mv cut find awk stat git(optional)
7878
</pre>
7979

8080
#### 2. Install CodeQuery
81-
* Follow installation guide in [CodeQuery project](https://github.com/ruben2020/codequery#how-to-install-it).
82-
* Enter `cqsearch -h` in your terminal and view the result. Make sure `cqsearch` accepts `-u` option.
83-
84-
> If not, you will have to pull latest CodeQuery code and then [build it](https://github.com/ruben2020/codequery/blob/master/doc/INSTALL-LINUX.md) yourself.
85-
81+
* Linux => Follow instructions [here](https://github.com/ruben2020/codequery/blob/master/doc/INSTALL-LINUX.md).
82+
* Mac => `brew install qscintilla2 qt5 cmake` and then pull latest CodeQuery code to [build it](https://github.com/ruben2020/codequery/blob/master/doc/INSTALL-LINUX.md).
83+
84+
> You will be able to simply type `brew install codequery` to install a new enough version of codequery in the future. 😑
8685
8786
#### 3. Install additional ctags/cscope tools for your languages
8887
| Language | Tools | How to install |
@@ -122,13 +121,13 @@ Plug 'devjoe/vim-codequery'
122121

123122
* Go to the (git) root directory of your project. Open vim and type:
124123
```vim
125-
" Indexing Python files
124+
" Index Python files
126125
:CodeQueryMakeDB python
127126
128-
" Or indexing Python + Javascript files
127+
" Or index Python + Javascript files
129128
:CodeQueryMakeDB python javascript
130129
```
131-
* That's all! `python.db`, `javascript.db` ... will be created in the root directory.
130+
* That's all. `python.db`, `javascript.db` ... will be created in the root directory.
132131
* It's recommended that you should use `:CodeQueryMoveDBToGitDir python` to hide the DB file to `.git/codequery/` directory. If you do so, next time you can call `:CodeQueryMakeDB` directly in any opened Python buffer to rebuild the DB file.
133132

134133

@@ -218,7 +217,7 @@ Plug 'devjoe/vim-codequery'
218217

219218
Currently, vim-codequery only provides [Unite](https://github.com/Shougo/unite.vim) menu because I love and use it a lot ⭐. There are two types of menu:
220219

221-
* **Open a complete Unite menu**
220+
* **Open a full Unite menu**
222221

223222
```vim
224223
:CodeQueryMenu Unite Full
@@ -257,9 +256,19 @@ nnoremap <space>\ :CodeQueryMenu Unite Magic<CR>A
257256
```vim
258257
nnoremap <space><CR> :CodeQuery Symbol<CR>
259258
260-
" Chain commands! To find possible tests (for python)
259+
" Chain commands to find possible tests (for python)
261260
nnoremap <space>t :CodeQuery Caller<CR>:CodeQueryFilter test_<CR>
262261
```
262+
263+
#### Find Text
264+
```vim
265+
" Custom your `CodeQuery Text` commands
266+
let g:codequery_find_text_cmd = 'Ack!'
267+
268+
let g:codequery_find_text_from_current_file_dir = 0
269+
" 0 => search from project dir (git root directory / the directory containing xxx.db file)
270+
" 1 => search from the directory containing current file
271+
```
263272

264273
#### Load Ctags File
265274
```vim
@@ -272,7 +281,7 @@ set tags+=./java_tags;/
272281
set tags+=./c_tags;/
273282
```
274283

275-
#### Clean Ctags, Cscope ... Files For Your Languages
284+
#### Clean Ctags, Cscope ... Files by Languages
276285
```vim
277286
" It accpepts a list of your languages written in lowercase
278287
let g:codequery_enable_auto_clean_languages = ['python']

0 commit comments

Comments
 (0)