init.lua🔗
General initialization of Neovim that is not handled by a plugin or NvChad.
General settings🔗
Highlight the columns textwidth+0
and textwidth+20
. The default value of
textwidth
is 80
.
TODO move to overrides or configs
-- LuaSnip uses rafamadriz/friendly-snippets
-- extend in snipmate format
vim.g.snipmate_snippets_path = vim.fn.stdpath "config" .. "/lua/custom/snippets"
File Types🔗
Add file types to specific file name patterns (
see vim.filetype). The file
type yaml.docker-compose
and yaml.ansible
is used for choosing a more
specific LSP server.
vim.filetype.add({
pattern = {
-- SSH config
['.*/.ssh/config.d/.*'] = 'sshconfig',
-- rofi config
['.*/.*.rasi'] = 'css',
-- Docker compose
['compose.ya?ml'] = 'yaml.docker-compose',
['docker-compose.ya?ml'] = 'yaml.docker-compose',
-- Ansible
['.*/playbooks/.*.ya?ml'] = 'yaml.ansible',
['.*/playbooks/.*/.*.ya?ml'] = 'yaml.ansible',
['.*/roles/.*/tasks/.*.ya?ml'] = 'yaml.ansible',
['.*/roles/.*/handlers/.*.ya?ml'] = 'yaml.ansible',
},
})
Securing gopass🔗
The tool gopass might use Neovim for editing secrets. Therefore, backup files or other external information storage must be disabled.