summaryrefslogtreecommitdiff
path: root/mut/neovim/compiler
diff options
context:
space:
mode:
authorMike Vink <mike1994vink@gmail.com>2023-10-06 23:10:55 +0200
committerMike Vink <mike1994vink@gmail.com>2023-10-06 23:10:55 +0200
commitcfaef26e8718916adcc68fbfb63b15f2389b2cd2 (patch)
tree3989af4514d31d0a5cb89e8b96d51210ad7bf152 /mut/neovim/compiler
parent654ec06ab6a885ea851c4cbf68d06a00b41b0e14 (diff)
move all the files
Diffstat (limited to 'mut/neovim/compiler')
-rw-r--r--mut/neovim/compiler/ansible-lint.vim11
-rw-r--r--mut/neovim/compiler/go-test.vim14
-rw-r--r--mut/neovim/compiler/helm.vim14
-rw-r--r--mut/neovim/compiler/racket.vim26
-rw-r--r--mut/neovim/compiler/terragrunt.vim21
5 files changed, 86 insertions, 0 deletions
diff --git a/mut/neovim/compiler/ansible-lint.vim b/mut/neovim/compiler/ansible-lint.vim
new file mode 100644
index 0000000..9427092
--- /dev/null
+++ b/mut/neovim/compiler/ansible-lint.vim
@@ -0,0 +1,11 @@
+if exists('current_compiler')
+ finish
+endif
+let current_compiler = 'go-test'
+
+if exists(':CompilerSet') != 2
+ command -nargs=* CompilerSet setlocal <args>
+endif
+
+CompilerSet makeprg=compile\ ansible-lint
+CompilerSet errorformat=%Z%f:%l\ %m,%Z%f:%l,%E%\\%%(%\\S%\\)%\\@=%m,%C%\\%%(%\\S%\\)%\\@=%m,%-G
diff --git a/mut/neovim/compiler/go-test.vim b/mut/neovim/compiler/go-test.vim
new file mode 100644
index 0000000..61442e5
--- /dev/null
+++ b/mut/neovim/compiler/go-test.vim
@@ -0,0 +1,14 @@
+if exists('current_compiler')
+ finish
+endif
+let current_compiler = 'go-test'
+
+if exists(':CompilerSet') != 2
+ command -nargs=* CompilerSet setlocal <args>
+endif
+
+" %f>%l:%c:%t:%n:%m
+CompilerSet makeprg=go\ test
+CompilerSet errorformat=%.%#:\ %m\ %f:%l,%.%#:\ %m\ at\ %f:%l%.%#,
+
+" vim: sw=2 sts=2 et
diff --git a/mut/neovim/compiler/helm.vim b/mut/neovim/compiler/helm.vim
new file mode 100644
index 0000000..7e4b21d
--- /dev/null
+++ b/mut/neovim/compiler/helm.vim
@@ -0,0 +1,14 @@
+if exists('current_compiler')
+ finish
+endif
+let current_compiler = 'go-test'
+
+if exists(':CompilerSet') != 2
+ command -nargs=* CompilerSet setlocal <args>
+endif
+
+CompilerSet makeprg=compile\ helm\ lint
+CompilerSet errorformat=\[%t%.%#\]%.%#\ template:\ %f:%l:%c:\ %m,
+ \\[%t%.%#\]\ %f:\ %m,
+
+" vim: sw=2 sts=2 et
diff --git a/mut/neovim/compiler/racket.vim b/mut/neovim/compiler/racket.vim
new file mode 100644
index 0000000..1f98a41
--- /dev/null
+++ b/mut/neovim/compiler/racket.vim
@@ -0,0 +1,26 @@
+if exists('current_compiler')
+ finish
+endif
+let current_compiler = 'go-test'
+
+if exists(':CompilerSet') != 2
+ command -nargs=* CompilerSet setlocal <args>
+endif
+
+" The errorformat can also use vim's regular expression syntax (albeit in a rather awkward way) which gives us a solution to the problem. We can use a non-capturing group and a zero-width assertion to require the presence of these signaling phrases without consuming them. This then allows the %m to pick them up. As plain regular expression syntax this zero-width assertion looks like:
+"
+" \%(undefined reference\|multiple definition\)\@=
+"
+" But in order to use it in efm we need to replace \ by %\ and % by %%
+
+
+CompilerSet makeprg=compile\ racket
+CompilerSet errorformat=\%Z%*\\S%.%#,
+ \%C\ \ \ %f:%l:%c,
+ \%C\ \ \ %f:%l:%c:\ %m,
+ \%C\ \ %.%#%\\%%(module%\\spath:%\\\|at\:%\\\|in\:%\\\|expected\:%\\\|given\:%\\)%\\@=%m,
+ \%C\ %.%#,
+ \%E%\\%%(%\\w%\\)%\\@=%f:%*\\d:%*\\d:\ %m,
+ \%E%*\\f:%*\\d:%*\\d:\ %m,
+ \%E%\\%%(%\\S%\\+:%\\\|%\.%\\+--%\\)%\\@=%m,
+" vim: sw=2 sts=2 et
diff --git a/mut/neovim/compiler/terragrunt.vim b/mut/neovim/compiler/terragrunt.vim
new file mode 100644
index 0000000..54f94ef
--- /dev/null
+++ b/mut/neovim/compiler/terragrunt.vim
@@ -0,0 +1,21 @@
+if exists('current_compiler')
+ finish
+endif
+let current_compiler = 'go-test'
+
+if exists(':CompilerSet') != 2
+ command -nargs=* CompilerSet setlocal <args>
+endif
+
+" The errorformat can also use vim's regular expression syntax (albeit in a rather awkward way) which gives us a solution to the problem. We can use a non-capturing group and a zero-width assertion to require the presence of these signaling phrases without consuming them. This then allows the %m to pick them up. As plain regular expression syntax this zero-width assertion looks like:
+"
+" \%(undefined reference\|multiple definition\)\@=
+"
+" But in order to use it in efm we need to replace \ by %\ and % by %%
+
+
+CompilerSet makeprg=terragrunt
+CompilerSet errorformat=%.%#level=%t%.%#msg=%f:%l%\\,%c-%*\\d:\ %m,
+ \%Z%m,
+ \%E-\ %m\ (at\ %f:%l\\,%c-%*\\d),
+" vim: sw=2 sts=2 et