Skip to content

Commit

Permalink
Merge pull request #3 from qvalentin/feature/custom-filetypes
Browse files Browse the repository at this point in the history
feat: add custom filetypes
  • Loading branch information
qvalentin authored Nov 14, 2024
2 parents da75b8a + 8dd01a3 commit cb50dc2
Show file tree
Hide file tree
Showing 2 changed files with 15 additions and 0 deletions.
13 changes: 13 additions & 0 deletions ftdetect/filetype.lua
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
vim.filetype.add({
pattern = {
[".*/templates/.*%.tpl"] = "helm",
[".*/templates/.*%.ya?ml"] = "helm",
[".*/templates/.*%.txt"] = "helm",
["helmfile.*%.ya?ml"] = "helm",
["helmfile.*%.ya?ml.gotmpl"] = "helm",
["values.*%.yaml"] = "yaml.helm-values",
},
filename = {
["Chart.yaml"] = "yaml.helm-chartfile",
},
})
2 changes: 2 additions & 0 deletions ftplugin/helm.lua
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
-- set up the gotmpl commentstring
vim.opt_local.commentstring = "{{/* %s */}}"

0 comments on commit cb50dc2

Please sign in to comment.