blob: cda6a34b2618297ac04e4fe0162583774ee8c741 (
plain) (
blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
|
-- vim.opt.shiftwidth = 4
vim.keymap.set('n', '<leader>i', function()
local iface = vim.fn.input('Impl: ')
if not iface or iface == '' then
return
end
require('internal.cursor').word(function(word)
vim.cmd('normal ][o')
local args = {
'impl',
'-dir',
vim.fn.expand('%:h:p'),
'"' .. string.lower(word:sub(0, 1)) .. ' *' .. word .. '"',
iface,
}
vim.cmd('r!' .. table.concat(args, ' '))
end)
end)
|