mirror of
https://codeberg.org/leana8959/.files.git
synced 2025-12-06 06:39:14 +00:00
add(nvim): helper to reload curry colorscheme
This commit is contained in:
parent
0539bbfefa
commit
3e199282b2
2 changed files with 27 additions and 2 deletions
17
.config/nvim/after/plugin/reload.lua
Normal file
17
.config/nvim/after/plugin/reload.lua
Normal file
|
|
@ -0,0 +1,17 @@
|
|||
-- helper to reload module
|
||||
|
||||
local usercmd = vim.api.nvim_create_user_command
|
||||
local map = vim.keymap.set
|
||||
local remove = require("plenary.reload").reload_module
|
||||
|
||||
usercmd("Reload", function(opts)
|
||||
remove(opts.fargs[1])
|
||||
require(opts.fargs[1])
|
||||
end, { nargs = 1 })
|
||||
|
||||
usercmd("ReloadCurry", function(_)
|
||||
remove("curry")
|
||||
require("curry").setup()
|
||||
end, {})
|
||||
|
||||
map("n", "<leader>rc", ":ReloadCurry<CR>")
|
||||
Loading…
Add table
Add a link
Reference in a new issue