mirror of
https://github.com/amix/vimrc
synced 2025-06-16 01:25:00 +08:00
Replace YanRing with yank-stack and update plugins
This commit is contained in:
@ -57,7 +57,8 @@ tools developed by the Go community to provide a seamless Vim experience.
|
||||
* Advanced source analysis tools utilizing `guru`, such as |:GoImplements|,
|
||||
|:GoCallees|, and |:GoReferrers|.
|
||||
* Precise type-safe renaming of identifiers with |:GoRename|.
|
||||
* Integrated and improved snippets, supporting `ultisnips` or `neosnippet`.
|
||||
* Integrated and improved snippets, supporting `ultisnips`, `neosnippet`,
|
||||
and `vim-minisnip`.
|
||||
* Share your current code to play.golang.org with |:GoPlay|.
|
||||
* On-the-fly information about the word under the cursor. Plug it into your
|
||||
custom Vim function.
|
||||
@ -136,7 +137,8 @@ The following plugins are supported for use with vim-go:
|
||||
|
||||
* Snippets:
|
||||
https://github.com/Shougo/neosnippet.vim or
|
||||
https://github.com/SirVer/ultisnips
|
||||
https://github.com/SirVer/ultisnips or
|
||||
https://github.com/joereynolds/vim-minisnip
|
||||
|
||||
* For a better documentation viewer check out:
|
||||
https://github.com/garyburd/go-explorer
|
||||
@ -147,7 +149,8 @@ The following plugins are supported for use with vim-go:
|
||||
* Interactive |:GoDecls| and |:GoDeclsDir|:
|
||||
https://github.com/ctrlpvim/ctrlp.vim or
|
||||
https://github.com/junegunn/fzf.vim or
|
||||
https://github.com/Shougo/unite.vim
|
||||
https://github.com/Shougo/unite.vim or
|
||||
https://github.com/Shougo/denite.nvim
|
||||
|
||||
==============================================================================
|
||||
COMMANDS *go-commands*
|
||||
@ -197,7 +200,8 @@ COMMANDS *go-commands*
|
||||
:GoDocBrowser [word]
|
||||
|
||||
Open the relevant GoDoc in browser for either the word[s] passed to the
|
||||
command or by default, the word under the cursor.
|
||||
command or by default, the word under the cursor. By default it opens the
|
||||
documentation in 'https://godoc.org'. To change it see |'g:go_doc_url'|.
|
||||
|
||||
*:GoFmt*
|
||||
:GoFmt
|
||||
@ -684,7 +688,7 @@ CTRL-t
|
||||
Requires `ctrlp.vim` or `fzf`; it will autodetect the plugin if installed,
|
||||
but you can use |'g:go_decls_mode'| to force using one or the other.
|
||||
By default `type` and `func` declarations are shown. This can be changed
|
||||
via |'g:go_decls_includes'|. Also see |unite-decls|.
|
||||
via |'g:go_decls_includes'|. Also see |unite-decls|, |denite-decls|.
|
||||
|
||||
*:GoDeclsDir*
|
||||
:GoDeclsDir [dir]
|
||||
@ -693,20 +697,27 @@ CTRL-t
|
||||
[dir] is given it parses the given directory.
|
||||
|
||||
*unite-decls*
|
||||
:Unite decls[:file or dir]
|
||||
*denite-decls*
|
||||
:Unite decls[:path]
|
||||
:Denite decls[:path]
|
||||
|
||||
Only enabled if `unite.vim` is installed. Show declarations for all
|
||||
functions and types on the current file or directory. If [:file or dir]
|
||||
is non empty, it parses the given one.
|
||||
Only enabled if `unite.vim` or `denite.nvim` is installed. Show
|
||||
declarations for all functions and types on the current file or directory
|
||||
or for [path] if given.
|
||||
|
||||
Note: `denite.nvim` requires NeoVim or Vim 8 with |:python3| enabled.
|
||||
>
|
||||
" show declarations on the parent directory of the current file
|
||||
:Unite decls
|
||||
:Denite decls
|
||||
|
||||
" show declarations on the file
|
||||
" show declarations in the file.
|
||||
:Unite decls:foo/bar.go
|
||||
:Denite decls:foo/bar.go
|
||||
|
||||
" show declarations on the directory
|
||||
" show declarations in the directory "foo".
|
||||
:Unite decls:foo
|
||||
:Denite decls:foo
|
||||
<
|
||||
*:GoImpl*
|
||||
:GoImpl [receiver] [interface]
|
||||
@ -1094,9 +1105,9 @@ SETTINGS *go-settings*
|
||||
*'g:go_test_prepend_name'*
|
||||
|
||||
Prepend the name of the failed test to each test message generated by a failed
|
||||
test. By default it is disabled.
|
||||
test. By default it is disabled.
|
||||
>
|
||||
let g:go_test_prepend_name = 0
|
||||
let g:go_test_prepend_name = 0
|
||||
<
|
||||
|
||||
*'g:go_test_timeout'*
|
||||
@ -1236,6 +1247,14 @@ Maximum height for the GoDoc window created with |:GoDoc|. Default is 20. >
|
||||
let g:go_doc_max_height = 20
|
||||
<
|
||||
|
||||
*'g:go_doc_url'*
|
||||
|
||||
godoc server URL used when |:GoDocBrowser| is used. Change if you want to use
|
||||
a private internal service. Default is 'https://godoc.org'.
|
||||
>
|
||||
let g:go_doc_url = 'https://godoc.org'
|
||||
<
|
||||
|
||||
*'g:go_def_mode'*
|
||||
|
||||
Use this option to define the command to be used for |:GoDef|. By default
|
||||
@ -1278,10 +1297,16 @@ Use this option to change default path for vim-go tools when using
|
||||
<
|
||||
*'g:go_snippet_engine'*
|
||||
|
||||
Use this option to define the default snippet engine. By default "ultisnips"
|
||||
is used. Use "neosnippet" for neosnippet.vim: >
|
||||
Define the snippet engine to use. The default is to auto-detect one. Valid
|
||||
values are:
|
||||
|
||||
let g:go_snippet_engine = "ultisnips"
|
||||
automatic Automatically detect a snippet engine.
|
||||
ultisnips https://github.com/SirVer/ultisnips
|
||||
neosnippet https://github.com/Shougo/neosnippet.vim
|
||||
minisnip https://github.com/joereynolds/vim-minisnip
|
||||
Note: the original at KeyboardFire/vim-minisnip won't work.
|
||||
>
|
||||
let g:go_snippet_engine = "automatic"
|
||||
<
|
||||
*'g:go_get_update'*
|
||||
|
||||
@ -1315,13 +1340,12 @@ remove build tags. By default it's not set.
|
||||
<
|
||||
*'g:go_autodetect_gopath'*
|
||||
|
||||
Automatically modifies GOPATH for certain directory structures, such as for
|
||||
the tool `godep` which has his own dependencies via the `Godeps` folder. What
|
||||
this means is that all tools are now working with the newly modified GOPATH.
|
||||
So |:GoDef| for example jumps to the source inside the `Godeps` (vendored)
|
||||
source. Currently `godep` and `gb` is supported, in the near future more tool
|
||||
supports will be added. By default it's disabled. >
|
||||
|
||||
Automatically modify GOPATH for certain directory structures, such as for
|
||||
the `godep` tool which stores dependencies in the `Godeps` folder. What this
|
||||
means is that all tools are now working with the newly modified GOPATH. So
|
||||
|:GoDef| for example jumps to the source inside the `Godeps` (vendored)
|
||||
source. Currently `godep` and `gb` are supported. By default it's disabled.
|
||||
>
|
||||
let g:go_autodetect_gopath = 0
|
||||
<
|
||||
*'g:go_textobj_enabled'*
|
||||
@ -1565,10 +1589,10 @@ By default the template file specified by |'g:go_template_file'| is used.
|
||||
<
|
||||
*'g:go_decls_includes'*
|
||||
|
||||
Only useful if `ctrlp.vim`, `unite.vim` or `fzf` are installed. This sets
|
||||
which declarations to show for |:GoDecls| (`ctrp.vim`) and |unite-decls|
|
||||
(`unite.vim`). It is a Comma delimited list Possible options are:
|
||||
{func,type}. The default is: >
|
||||
Only useful if `ctrlp.vim`, `unite.vim`, `denite.nvim` or `fzf` are installed.
|
||||
This sets which declarations to show for |:GoDecls| (`ctrp.vim`),
|
||||
|unite-decls| (`unite.vim`) and |denite-decls| (`denite.nvim`). It is a Comma
|
||||
delimited list. Possible options are: {func,type}. The default is: >
|
||||
|
||||
let g:go_decls_includes = 'func,type'
|
||||
<
|
||||
@ -1704,6 +1728,14 @@ Highlight operators such as `:=` , `==`, `-=`, etc.
|
||||
Highlight function names.
|
||||
>
|
||||
let g:go_highlight_functions = 0
|
||||
<
|
||||
*'g:go_highlight_function_arguments'*
|
||||
|
||||
Highlight the variable names in arguments and return values in function
|
||||
declarations. Setting this implies the functionality from
|
||||
|'g:go_highlight_functions'|.
|
||||
>
|
||||
let g:go_highlight_function_arguments = 0
|
||||
<
|
||||
*'g:go_highlight_methods'*
|
||||
|
||||
|
Reference in New Issue
Block a user