Skip to content

Commit 0b2afd8

Browse files
authored
Merge pull request #6 from rootiest/v1.6.5
V1.6.5 Documentation Fixes
2 parents 9b1f00b + 5d31b15 commit 0b2afd8

File tree

2 files changed

+36
-40
lines changed

2 files changed

+36
-40
lines changed

README.md

Lines changed: 18 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -44,6 +44,7 @@ To use the plugin with [lazy.nvim](https://github.com/folke/lazy.nvim):
4444
```lua
4545
{
4646
"rootiest/nvim-updater.nvim",
47+
version = "*", -- Pin to GitHub releases
4748
config = function()
4849
require("nvim_updater").setup({
4950
source_dir = "~/.local/src/neovim", -- Custom target directory
@@ -83,6 +84,7 @@ Minimal example with defaults in [lazy.nvim](https://github.com/folke/lazy.nvim)
8384
```lua
8485
{
8586
"rootiest/nvim-updater.nvim",
87+
version = "*", -- Pin to GitHub releases
8688
opts = {},
8789
}
8890
```
@@ -92,6 +94,7 @@ Example with [packer.nvim](https://github.com/wbthomason/packer.nvim):
9294
```lua
9395
use {
9496
"rootiest/nvim-updater.nvim",
97+
tag = "*", -- Pin to GitHub releases
9598
config = function()
9699
require("nvim_updater").setup({
97100
source_dir = "~/.local/src/neovim", -- Custom target directory
@@ -101,28 +104,23 @@ use {
101104
notify_updates = true, -- Enables update notifications
102105
default_keymaps = false, -- Disable default keymaps
103106
})
104-
end,
105-
keys = { -- Custom keymappings
106-
{ -- Custom Update Neovim
107-
"<Leader>cuU",
108-
function()
109-
require('nvim_updater').update_neovim()
110-
end,
111-
desc = "Custom Update Neovim"
112-
},
113-
{ -- Debug Build Neovim
114-
"<Leader>cuD",
115-
function()
116-
require('nvim_updater').update_neovim({ build_type = 'Debug' })
117-
end,
118-
desc = "Debug Build Neovim"
119-
},
120-
{ -- Remove Neovim Source
107+
108+
-- Define custom keymappings here
109+
vim.keymap.set("n", "<Leader>cuU", function()
110+
require('nvim_updater').update_neovim()
111+
end, { desc = "Custom Update Neovim" })
112+
113+
vim.keymap.set("n", "<Leader>cuD", function()
114+
require('nvim_updater').update_neovim({ build_type = 'Debug' })
115+
end, { desc = "Debug Build Neovim" })
116+
117+
vim.keymap.set(
118+
"n",
121119
"<Leader>cRN",
122120
":NVUpdateRemoveSource<CR>",
123-
desc = "Remove Neovim Source Directory",
124-
},
125-
}
121+
{ desc = "Remove Neovim Source Directory"
122+
})
123+
end,
126124
}
127125
```
128126

doc/nvim_updater.txt

Lines changed: 18 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -63,6 +63,7 @@ Example setup using lazy.nvim 󱞣
6363
>lua
6464
require("lazy").setup({
6565
"rootiest/nvim-updater.nvim",
66+
version = "*", -- Pin to GitHub releases
6667
config = function()
6768
require("nvim_updater").setup({
6869
source_dir = "~/.local/src/neovim", -- Custom target directory
@@ -99,6 +100,7 @@ Minimal example with defaults 󱞣
99100
>lua
100101
{
101102
"rootiest/nvim-updater.nvim",
103+
version = "*", -- Pin to GitHub releases
102104
opts = {},
103105
}
104106
<
@@ -107,6 +109,7 @@ Example with packer.nvim 󱞣
107109
>lua
108110
use {
109111
"rootiest/nvim-updater.nvim",
112+
tag = "*", -- Pin to GitHub releases
110113
config = function()
111114
require("nvim_updater").setup({
112115
source_dir = "~/.local/src/neovim", -- Custom target directory
@@ -116,28 +119,23 @@ Example with packer.nvim 󱞣
116119
notify_updates = true, -- Enables update notifications
117120
default_keymaps = false, -- Disable default keymaps
118121
})
119-
end,
120-
keys = { -- Custom keymappings
121-
{ -- Custom Update Neovim
122-
"<Leader>cuU",
123-
function()
124-
require('nvim_updater').update_neovim()
125-
end,
126-
desc = "Custom Update Neovim"
127-
},
128-
{ -- Debug Build Neovim
129-
"<Leader>cuD",
130-
function()
131-
require('nvim_updater').update_neovim({ build_type = 'Debug' })
132-
end,
133-
desc = "Debug Build Neovim"
134-
},
135-
{ -- Remove Neovim Source
122+
123+
-- Define custom keymappings here
124+
vim.keymap.set("n", "<Leader>cuU", function()
125+
require('nvim_updater').update_neovim()
126+
end, { desc = "Custom Update Neovim" })
127+
128+
vim.keymap.set("n", "<Leader>cuD", function()
129+
require('nvim_updater').update_neovim({ build_type = 'Debug' })
130+
end, { desc = "Debug Build Neovim" })
131+
132+
vim.keymap.set(
133+
"n",
136134
"<Leader>cRN",
137135
":NVUpdateRemoveSource<CR>",
138-
desc = "Remove Neovim Source Directory",
139-
},
140-
}
136+
{ desc = "Remove Neovim Source Directory"
137+
})
138+
end,
141139
}
142140
<
143141

0 commit comments

Comments
 (0)