Update README.md
This commit is contained in:
18
README.md
18
README.md
@@ -9,15 +9,13 @@ Plugin for calling [lazygit](https://github.com/jesseduffield/lazygit) from with
|
|||||||
Install using [`vim-plug`](https://github.com/junegunn/vim-plug):
|
Install using [`vim-plug`](https://github.com/junegunn/vim-plug):
|
||||||
|
|
||||||
```vim
|
```vim
|
||||||
" nvim v0.4.3
|
" nvim v0.5.0
|
||||||
Plug 'kdheepak/lazygit.nvim', { 'branch': 'nvim-v0.4.3' }
|
|
||||||
" nvim nightly
|
|
||||||
Plug 'kdheepak/lazygit.nvim'
|
Plug 'kdheepak/lazygit.nvim'
|
||||||
```
|
```
|
||||||
|
|
||||||
Feel free to use any plugin manager.
|
Feel free to use any plugin manager.
|
||||||
Just remember that if you are not using neovim nightly, you will need to use [the `nvim-v0.4.3` branch](https://github.com/kdheepak/lazygit.vim/tree/nvim-v0.4.3).
|
Just remember that if you are not using the latest neovim release, you will need to use [the `nvim-v0.4.3` branch](https://github.com/kdheepak/lazygit.vim/tree/nvim-v0.4.3).
|
||||||
Integration with `nvr` works better on the default branch.
|
Integration with `nvr` works better on the `main` branch.
|
||||||
|
|
||||||
You can check what version of `neovim` you have:
|
You can check what version of `neovim` you have:
|
||||||
|
|
||||||
@@ -42,7 +40,7 @@ And set up a mapping to call `:LazyGit`:
|
|||||||
|
|
||||||
```vim
|
```vim
|
||||||
" setup mapping to call :LazyGit
|
" setup mapping to call :LazyGit
|
||||||
nnoremap <silent> <leader>lg :LazyGit<CR>
|
nnoremap <silent> <leader>gg :LazyGit<CR>
|
||||||
```
|
```
|
||||||
|
|
||||||
Open the configuration file for `lazygit` directly from vim.
|
Open the configuration file for `lazygit` directly from vim.
|
||||||
@@ -59,9 +57,9 @@ If the file does not exist it'll load the defaults for you.
|
|||||||
|
|
||||||
If you have [neovim-remote](https://github.com/mhinz/neovim-remote) and have configured to use it in neovim, it'll launch the commit editor inside your neovim instance when you use `C` inside `lazygit`.
|
If you have [neovim-remote](https://github.com/mhinz/neovim-remote) and have configured to use it in neovim, it'll launch the commit editor inside your neovim instance when you use `C` inside `lazygit`.
|
||||||
|
|
||||||
1) `pip install neovim-remote`
|
1. `pip install neovim-remote`
|
||||||
|
|
||||||
2) Add the following to your `~/.bashrc`:
|
2. Add the following to your `~/.bashrc`:
|
||||||
|
|
||||||
```bash
|
```bash
|
||||||
if [ -n "$NVIM_LISTEN_ADDRESS" ]; then
|
if [ -n "$NVIM_LISTEN_ADDRESS" ]; then
|
||||||
@@ -69,7 +67,7 @@ if [ -n "$NVIM_LISTEN_ADDRESS" ]; then
|
|||||||
fi
|
fi
|
||||||
```
|
```
|
||||||
|
|
||||||
3) Set `EDITOR` environment variable in `~/.bashrc`:
|
3. Set `EDITOR` environment variable in `~/.bashrc`:
|
||||||
|
|
||||||
```bash
|
```bash
|
||||||
if [ -n "$NVIM_LISTEN_ADDRESS" ]; then
|
if [ -n "$NVIM_LISTEN_ADDRESS" ]; then
|
||||||
@@ -81,7 +79,7 @@ else
|
|||||||
fi
|
fi
|
||||||
```
|
```
|
||||||
|
|
||||||
4) Add the following to `~/.vimrc`:
|
4. Add the following to `~/.vimrc`:
|
||||||
|
|
||||||
```vim
|
```vim
|
||||||
if has('nvim') && executable('nvr')
|
if has('nvim') && executable('nvr')
|
||||||
|
|||||||
Reference in New Issue
Block a user