Add neovim-remote section to the README.md

This commit is contained in:
Dheepak Krishnamurthy
2020-04-05 13:54:34 -06:00
parent 3759d6ab85
commit a4ef118f32
2 changed files with 15 additions and 6 deletions

View File

@@ -1,6 +1,6 @@
# lazygit.nvim # lazygit.vim
Plugin for calling lazygit from within nvim. Plugin for calling lazygit from within neovim.
### Install ### Install
@@ -9,19 +9,19 @@ Use any plugin manager:
**[vim-plug](https://github.com/junegunn/vim-plug)** **[vim-plug](https://github.com/junegunn/vim-plug)**
```vim ```vim
Plug 'kdheepak/lazygit.nvim' Plug 'kdheepak/lazygit.vim'
``` ```
**[dein.vim](https://github.com/Shougo/dein.vim)** **[dein.vim](https://github.com/Shougo/dein.vim)**
```vim ```vim
call dein#add('kdheepak/lazygit.nvim') call dein#add('kdheepak/lazygit.vim')
``` ```
**[Vundle.vim](https://github.com/junegunn/vim-plug)** **[Vundle.vim](https://github.com/junegunn/vim-plug)**
```vim ```vim
Plugin 'kdheepak/lazygit.nvim' Plugin 'kdheepak/lazygit.vim'
``` ```
### Usage ### Usage
@@ -30,3 +30,12 @@ Plugin 'kdheepak/lazygit.nvim'
" lazygit " lazygit
nnoremap <silent> <leader>lg :LazyGit<CR> nnoremap <silent> <leader>lg :LazyGit<CR>
``` ```
### Using neovim-remote
Add the following to your `.gitconfig` to use your current neovim instance at the commit editor for git.
```
[core]
editor = nvr --remote-wait-silent
```

View File

@@ -65,7 +65,7 @@ function open_floating_window()
end end
local function project_root_dir() local function project_root_dir()
return fn.finddir('.git/..', fn.expand('%:p:h') .. ';') return fn.system('cd ' .. fn.expand('%:p:h') .. ' && git rev-parse --show-toplevel 2> /dev/null')
end end
local function execute(cmd, ...) local function execute(cmd, ...)