GithubHelp home page GithubHelp logo

vim-godef's Introduction

This plugin adds godef support to vim.

The godef tool from Roger Peppe parses Go code and returns the location of the definition of a symbol. It can be installed with

go get -v code.google.com/p/rog-go/exp/cmd/godef
go install -v code.google.com/p/rog-go/exp/cmd/godef

To install this plugin, copy godef.vim to ~/.vim/plugin .

Or, if you're using pathogen,

git clone https://github.com/dgryski/vim-godef ~/.vim/bundle/vim-godef

This modules overrides the gd (go to local definition) command to open a new window at the definition of the symbol under the cursor. Setting

g:godef_split=0

will reuse the current window, and

g:godef_split=2

will open the definition in a new tab.

If you want jumps to the same file to move your current cursor instead of splitting, use

g:godef_same_file_in_same_window=1

This also adds a :Godef which will work for global types, methods, constants, and variables in the current package.

vim-godef's People

Contributors

dgryski avatar myitcv avatar hoelzro avatar mattn avatar todoa2c avatar ficoos avatar zhouhua015 avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.