Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

impl: add vim-go-impl #846

Merged
merged 1 commit into from
May 10, 2016
Merged

impl: add vim-go-impl #846

merged 1 commit into from
May 10, 2016

Conversation

fatih
Copy link
Owner

@fatih fatih commented May 10, 2016

This adds the plugin https://github.com/rhysd/vim-go-impl with the
following changes/improvements:

  • :GoImpl can be now called without any arguments, in this case it
    assumes the identifier under the cursor to be the receiver type
  • :GoImpl io.Writer is a valid usage now, in this case it assumes the
    identifier under the cursor is the receiver type
  • Removed the restriction for completion that there needs to be at least
    three words. This is neede because :GoImpl io.Writer is now a valid
    expression.
  • We use now go doc for the auto completion. This allows for example
    the following usage as well :GoImpl json., in this case you can now
    complete to json.Unmarshaller, whereas godoc is not capable of doing
    it.
  • There is a newline prependend before we put the generated method stubs
  • Refactored to use internal functions of vim-go
  • Moved to autoload and load it lazily
  • Added docs to docs/vim-go.txt

Closes #122

Demo:
screen recording 2016-05-10 at 12 32 pm

/cc @rhysd

This adds the plugin https://github.com/rhysd/vim-go-impl with the
following changes/improvements:

* `:GoImpl` can be now called without any arguments, in this case it
  assumes the identifier under the cursor to be the receiver type
* `:GoImpl io.Writer` is a valid usage now, in this case it assumes the
  identifier under the cursor is the receiver type
* Removed the restriction for completion that there needs to be at least
  three words. This is neede because `:GoImpl io.Writer` is now a valid
  expression.
* We use now `go doc` for the auto completion. This allows for example
  the following usage as well `:GoImpl json.`, in this case you can now
  complete to json.Unmarshaller, whereas `godoc` is not capable of doing
  it.
* There is a newline prependend before we put the generated method stubs
* Refactored to use internal functions of vim-go
* Moved to `autoload` and load it lazily
* Added docs to `docs/vim-go.txt`

Closes #122

/cc @rhysd
@rhysd
Copy link
Contributor

rhysd commented May 10, 2016

LGTM 👍 Thank you for the integration ❤️

@fatih fatih merged commit 87a3bb9 into master May 10, 2016
@fatih fatih deleted the impl branch May 10, 2016 13:17
@fatih
Copy link
Owner Author

fatih commented May 10, 2016

@rhysd this is now merged. Would you like to add a note to https://github.com/rhysd/vim-go-impl to forward people to vim-go? Thanks to you too for the initial plugin!

@rhysd
Copy link
Contributor

rhysd commented May 10, 2016

@fatih I added a note to an introduction in README.

@fatih
Copy link
Owner Author

fatih commented May 10, 2016

Thanks @rhysd 👍

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants