hasundue / denops.vim

🐜 An ecosystem of Vim/Neovim which allows developers to write cross-platform plugins in Deno

Home Page:https://vim-denops.github.io/denops-documentation/

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool


Denops
An ecosystem of Vim/Neovim which allows developers to write plugins in Deno.

Deno 1.32 or above Vim 9.0.1499 or above Neovim 0.8.0 or above

MIT License deno land test reviewdog codecov

vim help deno doc Documentation

Quick start

First of all, install the latest Deno. See Deno's official manual for details.

Note that deno command need to be executable from Vim/Neovim. You can confirm it by exepath() function in Vim/Neovim like below:

:echo exepath('deno')
/usr/local/bin/deno

Or specify an absolute path to g:denops#deno variable (See :help g:denops#deno.)

Once you got deno to work, install vim-denops/denops.vim as a general Vim plugin. For example, the following uses vim-plug:

Plug 'vim-denops/denops.vim'
Plug 'vim-denops/denops-helloworld.vim'

Then you can confirm if denops is working properly by executing DenopsHello command like:

:DenopsHello
Hello

Once you've confirmed that denops is working, you can remove vim-denops/denops-helloworld.vim.

Shared server

Normally, a Denops server is started for each Vim/Neovim instance, but there are cases where the process startup becomes a bottleneck and impairs usability.

In such cases, launching a "Shared server" and connecting to it will allow all Vim/Neovim instances to use a shared server, thus avoiding the bottleneck of process launches and possibly improving usability.

To start the shared server, execute the following command in the denops.vim repository top

deno run -A --no-lock ./denops/@denops-private/cli.ts

Then specify the server address in g:denops_server_addr as follows

let g:denops_server_addr = '127.0.0.1:32123'

If you'd like to specify hostname and port, use --hostname and --port command arguments as follows

deno run -A --no-lock \
    ./denops/@denops-private/cli.ts \
    --hostname=0.0.0.0 \
    --port 12345

Documentations

To learn how to write Vim/Neovim plugins by denops, see Denops Documentation or denops.vim Wiki.

Support policy

Denops determines the supported versions of Vim/Neovim/Deno based on the following support policy when updating the major version:

  • For Vim, versions older than the latest version provided by Homebrew and the version distributed by vim-win32-installer
    • Windows users can install it by downloading the package from vim-win32-installer
    • macOS users can install it through Homebrew
    • Linux users have the flexibility to build any version they prefer
  • For Neovim/Deno, the two most recent minor versions

Versioning

Before v1.10.0, we defined that the version of denops.vim indicates that code versions of the entire repository. However, we changed this assumption from version v1.10.0. Now we defined the version of denops.vim indicates the version of the code in the denops/@denops directory that is published to deno.land as denops_core. That's why we won't bump versions when there are no changes on code in that directory.

Developers

Denops is mainly developed by members of vim-jp.

Inspired by

This ecosystem is strongly inspired by coc.nvim which allows developers to write Vim/Neovim plugin in Node.js.

License

The code follows MIT license written in LICENSE. Contributors need to agree that any modifications sent in this repository follow the license.

About

🐜 An ecosystem of Vim/Neovim which allows developers to write cross-platform plugins in Deno

https://vim-denops.github.io/denops-documentation/

License:MIT License


Languages

Language:Vim Script 51.7%Language:TypeScript 48.3%