/nvim-dvc

The long awaited dvc plugin for neovim

Primary LanguageLua


nvim-dvc

PR Lua

The DVC plugin for neovim

If only one could interact with DVC from within neovim. Oh wait, nvim-dvc does just that!

Installation

Install it using your favourite plugin manager; for instance if you are using vim-plug

Plug 'gennaro-tedesco/nvim-dvc'

Notice that this plugin makes use of bash core utils and jq internally (to parse DVC outputs), so it is recommended to have them installed.

Usage

nvim-dvc populates the location list with DVC stages and metrics files for easy access to models performances, or it enables to execute pipelines making use of prompt autocompletion, or it quickly opens up the DVC configurations. See demo below for a quick tour:

demo

Default commands:

command autocompletion description
DVCStages <Tab> populate the location list with DVC stages
DVCMetrics No populate the location list with DVC metrics files
DVCRepro <Tab> prompt autocompletion menu (after <Tab>) and execute stage
DVCFiles No populate the location list with all DVC tracked files
DVCConfig No open /.dvc/config for editing

The commands usage is self-explanatory, just invoke them and sit back; however, see :h dvc-usage (or :h <DVC-command>)for further help.

Customisation

If you prefer to populate the quickfix window rather than the location list simply override

lua require('nvim-dvc.config').use_quickfix = true

Feedback

Do not forget that the best way to browse metrics files and json in general is nvim-jqx.

If you find this plugin useful consider awarding it a ⭐, it is a great way to give feedback! Otherwise, any additional suggestions or merge request is warmly welcome!