Commit: cc87817d52b4300369cd1847eeb9ac969d3f4169
Parent: a2d313853fe60e77f0d68ff224825fb28556cd00
Author: Randy Palamar
Date: Fri, 20 May 2022 07:30:45 -0600
vis: add haskell formatting macro
Diffstat:
1 file changed, 4 insertions(+), 1 deletion(-)
diff --git a/.config/vis/macros.lua b/.config/vis/macros.lua
@@ -10,6 +10,9 @@ function macros(win)
{ 'normal', '\\se', 'i\\section{}<Escape>hi' },
{ 'normal', '\\su', 'i\\subsection{}<Escape>hi' },
}
+ lang['.hs'] = {
+ { 'normal', 'gq', 'vip:|hindent<Enter><Escape>'},
+ }
local f = win.file.name
if f == nil then return end
@@ -21,7 +24,7 @@ function macros(win)
if binds == nil then return end
for _, map in pairs(binds) do
- vis:command(string.format('map %s %s %s', map[1], map[2], map[3]))
+ vis:command(string.format('map! %s %s %s', map[1], map[2], map[3]))
end
end