refactor(filetype): reorganize mappings

This commit is contained in:
Ruslan
2026-06-27 12:29:38 +03:00
parent 1755c68818
commit 73ad16b985
+15 -7
View File
@@ -6,19 +6,27 @@ vim.filetype.add({
jinja2 = 'jinja',
},
pattern = {
-- gitlab-ci
['%.gitlab%-ci%.ya?ml'] = 'yaml.gitlab',
['pipelines/.*%.ya?ml'] = 'yaml.gitlab',
-- values files
['.*/helm/.*values.*%.ya?ml'] = 'yaml.helm-values',
['values%.ya?ml'] = 'yaml.helm-values',
-- ansible
['.*/molecule/.*%.ya?ml'] = 'yaml.ansible',
['.*/roles/.*%.ya?ml'] = 'yaml.ansible',
['.*/tasks/.*%.ya?ml'] = 'yaml.ansible',
['.*/plays/.*%.ya?ml'] = 'yaml.ansible',
['.*/plays/.*/files/.*%.ya?ml'] = { 'yaml', { priority = 10 } }, -- these are not ansible files
-- protobuf
['buf.yaml'] = 'buf-config',
['buf.gen.yaml'] = 'buf-config',
['buf.policy.yaml'] = 'buf-config',
['buf.lock'] = 'buf-config',
-- templates
['.*/templates/.*%.ya?ml'] = 'helm',
['.*/templates/.*%.tpl'] = 'helm',
['helmfile%.ya?ml'] = 'helm',
-- values files
['.*/helm/.*values.*%.ya?ml'] = 'yaml.helm-values',
['values%.ya?ml'] = 'yaml.helm-values',
-- gitlab-ci
['%.gitlab%-ci%.ya?ml'] = 'yaml.gitlab',
['pipelines/.*%.ya?ml'] = 'yaml.gitlab',
},
},
})