Code Monkey home page Code Monkey logo

Comments (11)

hrsh7th avatar hrsh7th commented on August 29, 2024 1

My plan.

  • Create vim-vsnip-integ repo
    • deoplete integration
    • Update README.md and doc.
  • VSCode extensions snippet detection in rtp.

from vim-vsnip.

hrsh7th avatar hrsh7th commented on August 29, 2024

Thanks!
I planning to create vim-vsnip-integ repo that will contains some integration codes.

runtimepath detection is nice idea.
I want to support vscode-extension directly.

For example.

Plug 'microsoft/vscode-python'

Currently nvim lsp seems has no integration point to snippet support...

from vim-vsnip.

pwntester avatar pwntester commented on August 29, 2024

Tried the deoplete integration but could not get it working. Is there anything needed apart from installing the plugin (with the deoplete source)?

I have the following in snippet test in my global.json file (at let g:vsnip_snippet_dir = "~/dotfiles/snippets"):

{
  "foo": {
    "prefix": "foo",
    "body": [
        "FOO $1"
    ],
    "description": "FOO TEST."
  }
}

Entering foo does not offer any snippet expansion

from vim-vsnip.

hrsh7th avatar hrsh7th commented on August 29, 2024

Thanks for try it!

I've added .vimrc file.
I got right results with it.

If you don't get right results, please give the more info e.g.) vim version, your vimrc etc...

My worked steps.

  1. $ nvim -u .vimrc
  2. :PlugInstall
  3. :qa!
  4. $ nvim -u .vimrc
  5. :UpdateRemotePlugins
  6. :qa!
  7. $ nvim -u .vimrc
  8. type fo

deoplete will suggest foo [vsnip] candidate, and snippet expanded with press <Tab>.

from vim-vsnip.

hrsh7th avatar hrsh7th commented on August 29, 2024

The minimal vimrc is here.
https://github.com/hrsh7th/vim-vsnip/blob/master/.vimrc

from vim-vsnip.

pwntester avatar pwntester commented on August 29, 2024

Thanks for the quick response. I tried your minimal vimrc + let g:vsnip_snippet_dir = "~/dotfiles/snippets" with the same results. Im using latest neovim (NVIM v0.5.0-nightly-588-g36d1335a6).

im getting the following output when running UpdateRemotePlugins:

remote/host: python3 host registered plugins ['deoplete']                                                                                                     remote/host: generated rplugin manifest: /Users/pwntester/.local/share/nvim/rplugin.vim

Should I see vim-vsnip-integ as well?

My dotfiles are located here: https://github.com/pwntester/dotfiles/tree/master/config/nvim

from vim-vsnip.

hrsh7th avatar hrsh7th commented on August 29, 2024

I understood the problem.
vim-vsnip used resolve() in autoload/vsnip/source.vim.
But it seems not expand ~/dotfiles/snippets to /home/pwntester/dotfiles/snippets.

I've change the resolve to using expand.
Please try it.

from vim-vsnip.

pwntester avatar pwntester commented on August 29, 2024

oh my fault then, I assume it was expanded.

After upgrading I can see the option in the deoplete menu and the snippets, get expanded.

I have some problems with tabstops though, will file a different defect for it, thanks!

from vim-vsnip.

hrsh7th avatar hrsh7th commented on August 29, 2024

I've implemented Detect VSCode snippets in rtp. feature.
If you have anytime, please try it (#9).

from vim-vsnip.

pwntester avatar pwntester commented on August 29, 2024

Jus tried it and works great for me, thanks!

from vim-vsnip.

hrsh7th avatar hrsh7th commented on August 29, 2024

Thanks for your idea! its useful for me too.

from vim-vsnip.

Related Issues (20)

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.