dotfiles-arch/.config/nvim/lua/vimopt.lua

33 lines
649 B
Lua
Raw Normal View History

2023-11-27 18:03:12 +00:00
local set = vim.opt
set.tabstop = 4
set.softtabstop = 4
set.shiftwidth = 4
--set.noexpandtab = true
set.mouse = "a"
set.clipboard = "unnamedplus"
set.hlsearch = true
set.autoindent = true
set.ttyfast = true
set.number = true
set.relativenumber = true
set.rnu = true
set.swapfile = false
2023-12-05 00:22:07 +00:00
vim.filetype.add({
pattern = {
['.*%.pl'] = 'prolog',
['.*%.prolog'] = 'prolog',
2024-01-22 23:34:10 +00:00
['.*%.php.m4'] = 'php',
2023-12-05 00:22:07 +00:00
}
})
2024-04-05 19:11:06 +00:00
vim.api.nvim_create_autocmd({ "BufWritePre" }, {
pattern = { "*" },
command = [[%s/\s\+$//e]],
})
vim.api.nvim_create_autocmd({ "BufWritePost" }, {
pattern = { "*.md" },
command = 'silent !pandoc % --output=/home/freya/.temp.pdf'
})