mirror of
https://github.com/js0ny/dotfiles.git
synced 2025-12-21 08:43:00 +00:00
nvim: ft keymaps via ftplugin/
This commit is contained in:
parent
51e6343b9e
commit
32429308f3
22 changed files with 112 additions and 213 deletions
|
|
@ -1,16 +1,9 @@
|
|||
vim.keymap.set("n", "<leader>mx", '<cmd>!chmod +x "%"<CR>', {
|
||||
desc = "Mark the file as executable",
|
||||
buffer = true
|
||||
})
|
||||
vim.keymap.set("i", "<C-m>x", '<cmd>!chmod +x "%"<CR>', {
|
||||
desc = "Mark the file as executable",
|
||||
buffer = true
|
||||
})
|
||||
vim.keymap.set("n", "<leader>mX", '<cmd>!chmod u+x "%"<CR>', {
|
||||
desc = "Mark the file as executable (current user only)",
|
||||
buffer = true
|
||||
})
|
||||
vim.keymap.set("i", "<C-m>X", '<cmd>!chmod u+x "%"<CR>', {
|
||||
desc = "Mark the file as executable (current user only)",
|
||||
buffer = true
|
||||
})
|
||||
local prefmap = {
|
||||
{ keys = "x", cmd = '<cmd>!chmod +x "%"<CR>', opts = { desc = "Mark the file as executable" } },
|
||||
{ keys = "X", cmd = '<cmd>!chmod u+x "%"<CR>', opts = { desc = "Mark the file as executable (current user only)" } },
|
||||
}
|
||||
|
||||
local set_buf_keymaps_prefix = require("keymaps.utils").set_buf_keymaps_prefix
|
||||
-- local set_buf_keymaps = require("keymaps.utils").set_buf_keymaps
|
||||
|
||||
set_buf_keymaps_prefix(prefmap)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue