The "did_ftplugin" lines were ineffective and the "K" mapping was too
invasive, which is why it was removed.
R=golang-dev, dsymonds, minux.ma
CC=golang-dev
https://golang.org/cl/
6823044
" It tries to preserve cursor position and avoids
" replacing the buffer with stderr output.
"
+if exists("b:did_ftplugin_go_fmt")
+ finish
+endif
command! -buffer Fmt call s:GoFormat()
call winrestview(view)
endfunction
+let b:did_ftplugin_go_fmt = 1
+
" vim:ts=4:sw=4:et
+++ /dev/null
-" Copyright 2011 The Go Authors. All rights reserved.
-" Use of this source code is governed by a BSD-style
-" license that can be found in the LICENSE file.
-"
-" godoc.vim: Vim command to see godoc.
-
-if exists("b:did_ftplugin")
- finish
-endif
-
-silent! nmap <buffer> <silent> K <Plug>(godoc-keyword)
-
-" vim:ts=4:sw=4:et
" The backslash is the default maplocalleader, so it is possible that
" your vim is set to use a different character (:help maplocalleader).
"
-if exists("b:did_ftplugin")
+if exists("b:did_ftplugin_go_import")
finish
endif
echohl Error | echo a:s | echohl None
endfunction
+let b:did_ftplugin_go_import = 1
+
" vim:ts=4:sw=4:et
1. Same as 1 above.
2. Copy or link plugin/godoc.vim to $HOME/.vim/plugin/godoc,
syntax/godoc.vim to $HOME/.vim/syntax/godoc.vim,
- ftplugin/go/godoc.vim to $HOME/.vim/ftplugin/go/godoc.vim.
and autoload/go/complete.vim to $HOME/.vim/autoload/go/complete.vim.