mirror of
https://github.com/pnx/dotfiles
synced 2026-06-16 19:30:01 +02:00
15 lines
348 B
Lua
15 lines
348 B
Lua
|
|
local M = {}
|
|
|
|
function M.setHardtabs(width)
|
|
width = width or 8
|
|
vim.cmd(string.format("setlocal noet ts=%s sts=0 sw=0", width))
|
|
end
|
|
|
|
---@param width number
|
|
function M.setSofttabs(width, isLocal)
|
|
isLocal = (isLocal or false) and "local" or ""
|
|
vim.cmd(string.format("set%s et ts=%s sts=0 sw=%s", isLocal, width, width))
|
|
end
|
|
|
|
return M
|