all repos — dotfiles @ 0cd32a4982c6e6f43b0d1473de0c5b8c7c6f8256

my *nix dotfiles

config/nvim/lua/utils.lua (view raw)

 1local M = {}
 2local cmd = vim.cmd
 3
 4function M.create_augroup(autocmds, name)
 5    cmd('augroup ' .. name)
 6    cmd('autocmd!')
 7    for _, autocmd in ipairs(autocmds) do
 8        cmd('autocmd ' .. table.concat(autocmd, ' '))
 9    end
10    cmd('augroup END')
11end
12
13function M.iabbrev(a, b)
14  cmd(string.format('iabbrev %s %s', a, b))
15end
16
17return M
18