From 56760339a81cd1540d5a72fd9d93010a2677b55d Mon Sep 17 00:00:00 2001 From: Mainak Mandal Date: Tue, 1 Oct 2024 13:45:16 +0200 Subject: [PATCH] docs: Update Lazy install instructions (#129) --- README.md | 64 +++++++++++++++++++++++++++++++------------------------ 1 file changed, 36 insertions(+), 28 deletions(-) diff --git a/README.md b/README.md index 7d68155..c345b13 100644 --- a/README.md +++ b/README.md @@ -33,23 +33,24 @@ Install using [`lazy.nvim`](https://github.com/folke/lazy.nvim): ```lua -- nvim v0.8.0 return { - "kdheepak/lazygit.nvim", - cmd = { - "LazyGit", - "LazyGitConfig", - "LazyGitCurrentFile", - "LazyGitFilter", - "LazyGitFilterCurrentFile", - }, - -- optional for floating window border decoration - dependencies = { - "nvim-lua/plenary.nvim", - }, - -- setting the keybinding for LazyGit with 'keys' is recommended in - -- order to load the plugin when the command is run for the first time - keys = { - { "lg", "LazyGit", desc = "LazyGit" } - } + "kdheepak/lazygit.nvim", + lazy = true, + cmd = { + "LazyGit", + "LazyGitConfig", + "LazyGitCurrentFile", + "LazyGitFilter", + "LazyGitFilterCurrentFile", + }, + -- optional for floating window border decoration + dependencies = { + "nvim-lua/plenary.nvim", + }, + -- setting the keybinding for LazyGit with 'keys' is recommended in + -- order to load the plugin when the command is run for the first time + keys = { + { "lg", "LazyGit", desc = "LazyGit" } + } } ``` @@ -226,18 +227,25 @@ Install using [`lazy.nvim`](https://github.com/folke/lazy.nvim): ```lua -- nvim v0.8.0 -require("lazy").setup({ - { - "kdheepak/lazygit.nvim", - dependencies = { - "nvim-telescope/telescope.nvim", - "nvim-lua/plenary.nvim" - }, - config = function() - require("telescope").load_extension("lazygit") - end, +{ + "kdheepak/lazygit.nvim", + lazy = false, + cmd = { + "LazyGit", + "LazyGitConfig", + "LazyGitCurrentFile", + "LazyGitFilter", + "LazyGitFilterCurrentFile", }, -}) + -- optional for floating window border decoration + dependencies = { + "nvim-telescope/telescope.nvim", + "nvim-lua/plenary.nvim", + }, + config = function() + require("telescope").load_extension("lazygit") + end, +} ``` Lazy loading `lazygit.nvim` for telescope functionality is not supported. Open an issue if you wish to have this feature.