Open *.srcjar as zip

This commit is contained in:
Christian Nieves
2024-08-21 16:11:25 +00:00
parent 1dfaac5950
commit d632924ca7
4 changed files with 12 additions and 10 deletions

View File

@ -0,0 +1,6 @@
vim.api.nvim_create_autocmd({ "BufReadCmd" }, {
pattern = "*.srcjar",
callback = function()
vim.api.nvim_command("call zip#Browse(expand('<amatch>'))")
end,
})

View File

@ -14,3 +14,4 @@ package.path = package.path .. ";" .. vim.env.HOME .. "/.vim/lua/?.lua"
require("lazy").setup("plugins")
require("config.clipboard")
require("config.zip")

View File

@ -7,14 +7,11 @@ return {
end,
config = function()
require("which-key").setup({})
-- local wk = require("which-key")
--
-- wk.register({ [";"] = { ":" } }, { mode = "v" })
-- wk.register({ [";"] = { ":" } }, { mode = "n" })
--
-- wk.register({
-- ["%%"] = { '<C-R>=fnameescape(expand("%:p:h")."/")<CR>', "Current File Directory" },
-- }, { mode = "c" })
local wk = require("which-key")
wk.register({
["%%"] = { '<C-R>=fnameescape(expand("%:p:h")."/")<CR>', "Current File Directory" },
["%."] = { "<C-R>%", "Current File" },
}, { mode = "c" })
--
-- wk.register({
-- ["jk"] = { "<esc>" },

View File

@ -12,8 +12,6 @@ map <Esc>[D <Left>
" remove mapping to be used in nerdtree
inoremap <Nul> <C-n>
cnoremap %% <C-R>=fnameescape(expand("%:p:h")."/")<CR>
" move vertically by visual line
" nnoremap j gj
" nnoremap k gk