Anonymous avatar Anonymous committed 2332073

added fuzzyfinder.txt

Comments (0)

Files changed (2)

doc/fuzzyfinder.txt

+*fuzzyfinder.txt*       Fuzzy/Partial pattern explorer for buffer/file/etc.
+
+
+==============================================================================
+INTRODUCTION                                        *fuzzyfinder-introduction*
+
+Fuzzyfinder provides convenient ways to quickly reach the buffer/file you
+want. Fuzzyfinder finds matching files/buffers with a fuzzy/partial pattern to
+which it converted the entered pattern. 
+
+  entered pattern  fuzzy pattern             partial pattern ~
+  abc              * a * b * c *             * abc *
+  a?c              * a ? c *                 * a ? c *
+  dir/file         dir/ * f * i * l * e *    dir/ * file *
+  d*r/file         d * r/ * f * i * l * e *  d * r/ * file *
+  ../**/s          ../ ** /*s*               ../ ** / * s *
+                   (** allows searching a directory tree.)
+
+You will be happy when:
+
+  "./OhLongLongLongLongLongFile.txt"
+  "./AhLongLongLongLongLongName.txt"
+  "./AhLongLongLongLongLongFile.txt" <- you want :O
+
+Type "AF" and "AhLongLongLongLongLongFile.txt" will be select. :D
+
+Fuzzyfinder has some modes:
+
+  Buffer mode
+  File mode
+  Directory mode (yet another :cd command)
+  MRU-File mode (most recently used files)
+  MRU-Command mode (most recently used command-lines)
+  Bookmark mode
+  Tag mode (yet another :tag command)
+  Tagged-File mode (files which are included in current tags)
+
+Fuzzyfinder supports multibyte characters.
+
+
+==============================================================================
+USAGE                                                      *fuzzyfinder-usage*
+
+                                                          *fuzzyfinder-launch*
+Launching ~
+
+You can launch Fuzzyfinder by the following commands:
+
+  :FuzzyFinderBuffer - launchs Fuzzyfinder as Buffer mode.
+  :FuzzyFinderFile - launchs Fuzzyfinder as File mode.
+  :FuzzyFinderDir - launchs Fuzzyfinder as Directory mode.
+  :FuzzyFinderMruFile - launchs Fuzzyfinder as MRU-File mode.
+  :FuzzyFinderMruCmd - launchs Fuzzyfinder as MRU-Command mode.
+  :FuzzyFinderBookmark - launchs Fuzzyfinder as Bookmark mode.
+  :FuzzyFinderTag - launchs Fuzzyfinder as Tag mode.
+  :FuzzyFinderTaggedFile - launchs Fuzzyfinder as Tagged-File mode.
+
+It is recommended to map these commands. These commands can take initial text
+as a command argument. The text will be entered after Fuzzyfinder launched. If
+a command was executed with a ! modifier (e.g. :FuzzyFinderTag!), it enables
+the partial matching instead of the fuzzy matching.
+
+                                                    *fuzzyfinder-manipulation*
+Manipulation ~
+
+An entered pattern is converted to a fuzzy pattern and items which match the
+pattern is shown in a completion menu.
+
+A completion menu is shown when you type at an end of a line and the length of
+the entered pattern is more than setting value. By default, it is shown at the
+beginning.
+
+The number of items shown in the completion menu is limited (100, by default)
+to speed up the response time.
+
+Fuzzyfinder sorts completion items with some rules:
+
+  A perfect matching puts first.
+  A sequential matching puts higher than a fragmentary matching.
+  A backward matching puts higher than a forward matching.
+  A short item is put higher than a long item.
+
+Plus, Fuzzyfinder has a learning system. An item which has been completed in
+the past with a current pattern is placed upper.
+
+The first item in the completion menu will be selected automatically.
+
+You can open a selected item in various ways:
+
+  <CR> - opens in a previous window.
+  <C-j> - opens in a split window.
+  <C-k> - opens in a vertical-split window.
+  <C-]> - opens in a new tab page.
+
+To cancel and return to previous window, leave Insert mode.
+
+To Switch the mode without leaving Insert mode, use <C-l> or <C-o>. This key
+mapping is customizable.
+
+If you want to temporarily change whether or not to ignore case, use <C-t>.
+This key mapping is customizable.
+
+                                                  *fuzzyfinder-reusing-window*
+Reusing Of A Window Containing Target Buffer ~
+
+If a window containing target buffer is found in current tab page when
+Fuzzyfinder is going to open the buffer in a split new window, move to it. If
+a window containing target buffer is found in other tab page when Fuzzyfinder
+is going to open the buffer in a new tab page, move to it.
+
+You can disable that feature via 'reuse_window' option if always want to open
+a buffer in a new window.
+
+                                                     *fuzzyfinder-hiding-menu*
+To Hide The Completion Menu Temporarily In Fuzzyfinder ~
+
+You can close it by <C-e> and reopen it by <C-x><C-u>.
+
+                                                    *fuzzyfinder-highlighting*
+About Highlighting ~
+
+Fuzzyfinder highlights the buffer with "Error" group when the number of
+completion items found is 0 or over enumerating_limit.
+
+                                                     *fuzzyfinder-command-arg*
+About Usage Of Command Argument ~
+
+As an example, if you want to launch file-mode Fuzzyfinder with the full path
+of current directory, map like below:
+>
+  nnoremap <C-p> :FuzzyFinderFile <C-r>=fnamemodify(getcwd(), ':p')<CR><CR>
+<
+Instead, if you want the directory of current buffer and not current directory:
+>
+  nnoremap <C-p> :FuzzyFinderFile <C-r>=expand('%:~:.')[:-1-len(expand('%:~:.:t'))]<CR><CR>
+<
+                                                    *fuzzyfinder-abbreviation*
+                                                 *fuzzyfinder-multiple-search*
+About Abbreviations And Multiple Search ~
+
+You can use abbreviations and multiple search in each mode. For example, set
+as below:
+>
+  let g:FuzzyFinderOptions.Base.abbrev_map  = {
+        \   "^WORK" : [
+        \     "~/project/**/src/",
+        \     ".vim/plugin/",
+        \   ],
+        \ }
+<
+And type "WORKtxt" in file-mode Fuzzyfinder, then it searches by following
+patterns:
+
+  "~/project/**/src/*t*x*t*"
+  ".vim/plugin/*t*x*t*"
+
+                                                *fuzzyfinder-information-file*
+About Information File ~
+
+Fuzzyfinder writes information of the MRU, bookmark, etc to the file by
+default (~/.vimfuzzyfinder).
+
+:FuzzyFinderEditInfo command is helpful in editing your information file. This
+command reads the information file in new unnamed buffer. Write the buffer and
+the information file will be updated.
+
+                                                           *fuzzyfinder-cache*
+About Cache ~
+
+Once a cache was created, It is not automatically updated to speed up the
+response time by default. To update it, use :FuzzyFinderRemoveCache command.
+
+                                                   *fuzzyfinder-bookmark-mode*
+About Bookmark Mode ~
+
+You can jump to a line you have added to bookmarks beforehand. Fuzzyfinder
+adjusts a line number for jump. If a line of bookmarked position does not
+match to a pattern when the bookmark was added, Fuzzyfinder searches a
+matching line around bookmarked position. So you can jump to a bookmarked line
+even if the line is out of bookmarked position. If you want to jump to
+bookmarked line number, set g:FuzzyFinderOptions.Bookmark.searching_range
+option to 0.
+
+                                                 *fuzzyfinder-adding-bookmark*
+Adding Bookmark ~
+
+You can add a cursor line to bookmarks by :FuzzyFinderAddBookmark command.
+Execute that command and you will be prompted to enter a bookmark name.
+
+                                                     *fuzzyfinder-alt-tagjump*
+About Alternative Approach For Tag Jump ~
+
+Following mappings are replacements for :tag and <C-]>:
+>
+  nnoremap <silent> <C-f><C-t> :FuzzyFinderTag!<CR>
+  nnoremap <silent> <C-]>      :FuzzyFinderTag! <C-r>=expand('<cword>')<CR><CR>In the tag mode, it is recommended to use partial matching instead of fuzzy matching.
+<
+                                                 *fuzzyfinder-taggedfile-mode*
+About Tagged File Mode ~
+
+The files which are included in the current tags are the ones which are
+related to the current working environment. So this mode is a pseudo project
+mode.
+
+                                                          *fuzzyfinder-migemo*
+About Migemo ~
+
+Migemo is a search method for Japanese language.
+
+==============================================================================
+OPTIONS                                                  *fuzzyfinder-options*
+
+You can set options via g:FuzzyFinderOptions which is a dictionary. See the folded section named "GLOBAL OPTIONS:" for details. To easily set options for customization, put necessary entries from GLOBAL OPTIONS into your vimrc file and edit those values.
+
+
+==============================================================================
+VIMRC EXAMPLE                                      *fuzzyfinder-vimrc-example*
+
+>
+  let g:FuzzyFinderOptions = { 'Base':{}, 'Buffer':{}, 'File':{}, 'Dir':{}, 'MruFile':{}, 'MruCmd':{}, 'Bookmark':{}, 'Tag':{}, 'TaggedFile':{}}
+  let g:FuzzyFinderOptions.Base.ignore_case = 1
+  let g:FuzzyFinderOptions.Base.abbrev_map  = {
+        \   '\C^VR' : [
+        \     '$VIMRUNTIME/**',
+        \     '~/.vim/**',
+        \     '$VIM/.vim/**',
+        \     '$VIM/vimfiles/**',
+        \   ],
+        \ }
+  let g:FuzzyFinderOptions.MruFile.max_item = 200
+  let g:FuzzyFinderOptions.MruCmd.max_item = 200
+  nnoremap <silent> <C-n>      :FuzzyFinderBuffer<CR>
+  nnoremap <silent> <C-m>      :FuzzyFinderFile <C-r>=expand('%:~:.')[:-1-len(expand('%:~:.:t'))]<CR><CR>
+  nnoremap <silent> <C-j>      :FuzzyFinderMruFile<CR>
+  nnoremap <silent> <C-k>      :FuzzyFinderMruCmd<CR>
+  nnoremap <silent> <C-p>      :FuzzyFinderDir <C-r>=expand('%:p:~')[:-1-len(expand('%:p:~:t'))]<CR><CR>
+  nnoremap <silent> <C-f><C-d> :FuzzyFinderDir<CR>
+  nnoremap <silent> <C-b>      :FuzzyFinderBookmark<CR>
+  nnoremap <silent> <C-f><C-t> :FuzzyFinderTag!<CR>
+  nnoremap <silent> <C-f><C-g> :FuzzyFinderTaggedFile<CR>
+  noremap  <silent> g]         :FuzzyFinderTag! <C-r>=expand('<cword>')<CR><CR>
+  nnoremap <silent> <C-f>b     :FuzzyFinderAddBookmark<CR>
+  nnoremap <silent> <C-f><C-e> :FuzzyFinderEditInfo<CR>
+<
+
+==============================================================================
+SPECIAL THANKS                                            *fuzzyfinder-thanks*
+
+- Vincent Wang
+- Ingo Karkat
+- Nikolay Golubev
+- Brian Doyle
+- id:secondlife
+- Matt Tolton
+
+==============================================================================
+ vim:tw=78:ts=8:ft=help:norl:

plugin/fuzzyfinder.vim

-" TODO: update wiki:
-"   REUSING OF A WINDOW CONTAINING TARGET BUFFER:
-"
-"   If a window containing target buffer is found in current tab page when
-"   Fuzzyfinder is going to open the buffer in a split new window, move to it.
-"   If a window containing target buffer is found in other tab page when
-"   Fuzzyfinder is going to open the buffer in a new tab page, move to it.
-"
-"   You can disable that feature via 'reuse_window' option if always
-"   want to open a buffer in a new window.
 "=============================================================================
 " fuzzyfinder.vim : Fuzzy/Partial pattern explorer for
 "                   buffer/file/MRU/command/bookmark/tag/etc.
Tip: Filter by directory path e.g. /media app.js to search for public/media/app.js.
Tip: Use camelCasing e.g. ProjME to search for ProjectModifiedEvent.java.
Tip: Filter by extension type e.g. /repo .js to search for all .js files in the /repo directory.
Tip: Separate your search with spaces e.g. /ssh pom.xml to search for src/ssh/pom.xml.
Tip: Use ↑ and ↓ arrow keys to navigate and return to view the file.
Tip: You can also navigate files with Ctrl+j (next) and Ctrl+k (previous) and view the file with Ctrl+o.
Tip: You can also navigate files with Alt+j (next) and Alt+k (previous) and view the file with Alt+o.