Skip to content

Commit 4483fc9

Browse files
author
yssl
committed
Update doc for 1.2.0
1 parent 033b765 commit 4483fc9

File tree

1 file changed

+59
-59
lines changed

1 file changed

+59
-59
lines changed

doc/VIntSearch.txt

Lines changed: 59 additions & 59 deletions
Original file line numberDiff line numberDiff line change
@@ -18,50 +18,47 @@ Contents *VIntSearch-contents*
1818
==============================================================================
1919
1. Introduction *VIntSearch-intro*
2020

21-
|VIntSearch| provides a unified interface for symbols or text search in vim.
22-
It supports two search methods (i.e. ctags and grep) and shows results
23-
in an integrated way as its name indicates (VIntSearch - Vi Integrated Search).
21+
|VIntSearch| is a vim plugin providing an integrated interface across various types of searches. It currently supports symbol search (by ctags) and text search (by grep).
22+
Search results are given in the quickfix window and a user can conviniently move to previous or next search results via the integrated search stack.
23+
VIntSearch means Vim Integrated Search.
2424

2525
## Features
2626

27-
- Quickfix-listed results from ctags search
27+
- Quickfix-listed search results for all types of searches
2828

29-
- Easier commands for grep search
29+
- Integrated search stack containing search history for all types of searches
30+
(similar to vim's tag stack, but more general one)
3031

31-
- Unified search stack containing your search history by grep and ctags
32-
(similar usage to vim's tag stack, but more general one)
33-
34-
- Unified search path for grep and ctags
35-
36-
- Various search commands (for word under the cursor, visually selected text
37-
, or any text you type)
32+
- Unified search path for all search types
3833

3934
- Stacking not only search keywords and their position, but also search results
40-
in Quickfix
35+
in the quickfix
36+
37+
- Search keyword can be from a word under the cursor, visually selected text,
38+
or any string you type.
4139

4240
==============================================================================
4341
2. Getting Started *VIntSearch-gettingstarted*
4442

45-
1. You need Exuberant Ctags to fully use this plugin.
46-
If you don't have it, please install it first.
43+
1. You need Exuberant Ctags to fully use this plugin. If you don't have it, please install it first: `sudo apt-get install exuberant-ctags`.
4744

4845
2. Install this plugin.
4946

5047
3. Open one of your source files with vim.
5148

52-
4. Build a tag file by typing **:VIntSearchBuildTag**. The tag file will be c
49+
4. Build a tag file by typing |:VIntSearchBuildTag|. The tag file will be c
5350
reated in the nearest ancestor dir of the source file that contains
5451
a repository dir such as `.git`,
5552
or in the current working dir if the source file is not managed by any
5653
version control system.
57-
(Type `:help |g:vintsearch_searchpathmode|` for more detail)
54+
(Type `:help g:vintsearch_searchpathmode` for more detail)
5855

5956
5. Note that your `set tags=...` setting should have `./tags;,tags;` to use
6057
the generated tag file.
6158
(The name of the tag file can be changed by setting |g:vintsearch_tagfilename|)
6259

6360
6. Move the cursor to one of the functions or variables.
64-
Typing |:VIntSearchListCursorGrep| or |:VIntSearchListCursorCtags| will
61+
Typing |:VIntSearchGrepCursor| n l or |:VIntSearchCtagsCursor| n l will
6562
give search results in Quickfix.
6663
Typing |:VIntSearchPrintStack| will show the search stack.
6764

@@ -82,46 +79,37 @@ Build a tag file for the search path.
8279
==============================================================================
8380
4. Search Commands *VIntSearch-searchcommands*
8481

85-
All following commands search the *search path* recursively, except ~Local commands.
86-
Search results are updated in Quickfix.
87-
88-
*:VIntSearchListCursorGrep*
89-
*:VIntSearchListCursorCtags*
90-
Search for a word under the cursor by grep or ctags.
91-
92-
*:VIntSearchJumpCursorGrep*
93-
*:VIntSearchJumpCursorCtags*
94-
Search for a word under the cursor by grep or ctags and jump to the first result.
82+
*:VIntSearchCtags* [keyword], *:VSctags* [keyword]
83+
Search for [keyword] by ctags.
9584

96-
*:VIntSearchListSelectionGrep*
97-
*:VIntSearchListSelectionCtags*
98-
Search for visually selected text by grep or ctags.
85+
*:VIntSearchGrep* [keyword] [grep_options], *:VSgrep* [keyword] [grep_options]
86+
Search for [keyword] by grep with [grep_options]. (See `man grep` for more details about [grep_options])
9987

100-
*:VIntSearchJumpSelectionGrep*
101-
*:VIntSearchJumpSelectionCtags*
102-
Search for visually selected text by grep or ctags and jump to the first result.
88+
*:VIntSearchCFGrep* [keyword] [grep_options], *:VScfgrep* [keyword] [grep_options]
89+
Search for [keyword] by grep with [grep_options] in the current file.
10390

104-
*:VIntSearchListTypeGrep* [keyword] [options], *:VSgrep* [keyword] [options]
105-
Search for [keyword] by grep with [options].
106-
(See `man grep` for more details about [options])
91+
*:VIntSearchCtagsCursor* [vimmode] [action]
92+
Search for keyword under the cursor by ctags.
10793

108-
*:VIntSearchListTypeCtags* [keyword], *:VSctags* [keyword]
109-
Search for [keyword] by ctags.
94+
[vimmode] can be one of:
95+
- 'n' : Use this if vim is in normal mode. Then keyword is the word under the cursor.
96+
- 'v' : Use this if vim is in visual mode. Then keyword is the visually selected text.
11097

111-
*:VIntSearchListCursorGrepLocal*
112-
Search for a word under the cursor by grep in the current file.
98+
[action] can be one of:
99+
- 'l' : List search result in the quickfix window and open the quickfix window.
100+
- 'j' : Jump to the first search result. The quickfix window is also updated but not opened.
113101

114-
*:VIntSearchListSelectionGrepLocal*
115-
Search for visually selected text by grep in the current file.
102+
*:VIntSearchGrepCursor* [vimmode] [action]
103+
Search for keyword under the cursor by grep.
116104

117-
*:VIntSearchListTypeGrepLocal* [keyword] [options], *:VSgrepL* [keyword] [options]
118-
Search for [keyword] by grep with [options] in the current file.
105+
*:VIntSearchCFGrepCursor* [vimmode] [action]
106+
Search for keyword under the cursor by grep in the current file.
119107

120108
==============================================================================
121109
5. Stack Commands *VIntSearch-stackcommands*
122110

123111
Search stack contains your search history - search keywords you jumped to,
124-
from which file, and search results in Quickfix also.
112+
from which file, and search results in the quickfix also.
125113
You can browse your source code more easily by moving forward and backward
126114
in the search stack.
127115

@@ -141,11 +129,11 @@ Clear the search stack.
141129
*:VScnext*
142130
*:VScprev*
143131
Replacement of vim's |:cc|, |:cnext|, and |:cprev| commands.
144-
Jumping to a new QuickFix item should be done ONLY using these commands.
132+
Jumping to a new quickFix item should be done ONLY using these commands.
145133
If not, the jump will not be reflected in VIntSearch's search stack .
146134
- If you're using any key mapings for |:cnext| or |:cprev|, you can just replace them
147135
with |:VScnext| and |:VScprev|.
148-
- When you `Enter` or `Double-click on a Quickfix item, VIntSearch will automatically
136+
- When you `Enter` or `Double-click on a quickfix item, VIntSearch will automatically
149137
call |:VScc| instead of vim's |:cc| command.
150138

151139
You can disable this VIntSearch's default `Enter` behavior
@@ -222,9 +210,9 @@ Default: >
222210

223211
*g:vintsearch_enable_default_quickfix_enter*
224212
You can enable / disable VIntSearch's default `Enter` behavior - calling
225-
|:VScc| when `Enter' or 'Double-click' is invoked in QuickFix window.
213+
|:VScc| when `Enter' or 'Double-click' is invoked in the quickFix window.
226214
This is useful when you use other plugins that also override `Enter' or
227-
'Double-click' behavior of QuickFix,
215+
'Double-click' behavior of the quickFix,
228216
such as [QFEnter](http://www.vim.org/scripts/script.php?script_id=4778).
229217
(For example, if you want use `Enter` and `Double-click` behavior of QFEnter,
230218
you have to disable this option.)
@@ -247,17 +235,19 @@ function! s:nnoreicmap(option, shortcut, command)
247235
endfunction
248236

249237
" VIntSearch
250-
call s:nnoreicmap('','<A-b>',':VIntSearchBuildTag<CR><CR>')
251-
call s:nnoreicmap('','<A-]>',':VIntSearchJumpCursorCtags<CR>')
252-
call s:nnoreicmap('','<A-\>',':VIntSearchJumpCursorGrep<CR><CR>')
253-
call s:nnoreicmap('','<A-g>]',':VIntSearchListCursorCtags<CR>')
254-
call s:nnoreicmap('','<A-g>\',':VIntSearchListCursorGrep<CR><CR>')
255238
call s:nnoreicmap('','<A-t>',':VIntSearchMoveBackward<CR>')
256239
call s:nnoreicmap('','<A-T>',':VIntSearchMoveForward<CR>')
257-
vnoremap <A-]> :<C-u>VIntSearchJumpSelectionCtags<CR>
258-
vnoremap <A-\> :<C-u>VIntSearchJumpSelectionGrep<CR><CR>
259-
vnoremap <A-g>] :<C-u>VIntSearchListSelectionCtags<CR>
260-
vnoremap <A-g>\ :<C-u>VIntSearchListSelectionGrep<CR><CR>
240+
241+
call s:nnoreicmap('','<A-]>',':VIntSearchCtagsCursor n j<CR>')
242+
call s:nnoreicmap('','g]',':VIntSearchCtagsCursor n l<CR>')
243+
call s:nnoreicmap('','g\',':VIntSearchGrepCursor n l<CR><CR>')
244+
vnoremap <A-]> :<C-u>VIntSearchCtagsCursor v j<CR>
245+
vnoremap g] :<C-u>VIntSearchCtagsCursor v l<CR>
246+
vnoremap g\ :<C-u>VIntSearchGrepCursor v l<CR><CR>
247+
248+
call s:nnoreicmap('','g\|',':VIntSearchCFGrepCursor n l<CR><CR>')
249+
vnoremap g\| :<C-u>VIntSearchCFGrepCursor v l<CR><CR>
250+
261251
call s:nnoreicmap('','<F8>',':VScnext<CR>')
262252
call s:nnoreicmap('','<S-F8>',':VScprev<CR>')
263253
```
@@ -271,6 +261,16 @@ to use alt-key mappings.
271261
==============================================================================
272262
8. Changelog *VIntSearch-changelog*
273263

264+
1.2.0 2015/06/07
265+
- Fix find option bug related to grep search
266+
- Rename & refactor all commands and whole code.
267+
The old commands (e.g. :VIntSearchListCursorGrep) are deprecated and will
268+
be removed in 1.3.0 version.
269+
1.1.3 2015/05/29
270+
- Update key mapping example
271+
- Update documents for Search Path / Tag Commands
272+
- Add VSbtag command
273+
- Fix :helptag build error
274274
1.1.2 2015/05/26
275275
- Add local search commands (search in current file)
276276
- Escaping double quotation mark in search keyword

0 commit comments

Comments
 (0)