forked from foxora/nix
changed gleam indentation and telescope preview indentation
This commit is contained in:
parent
db539dbfaf
commit
97611185fc
1 changed files with 10 additions and 7 deletions
|
|
@ -1,5 +1,5 @@
|
|||
vim.api.nvim_create_autocmd("FileType", {
|
||||
pattern = "lua",
|
||||
pattern = { "lua", "nix", "gleam" },
|
||||
callback = function()
|
||||
vim.opt_local.shiftwidth = 2
|
||||
vim.opt_local.tabstop = 2
|
||||
|
|
@ -7,11 +7,14 @@ vim.api.nvim_create_autocmd("FileType", {
|
|||
end,
|
||||
})
|
||||
|
||||
vim.api.nvim_create_autocmd("FileType", {
|
||||
pattern = "nix",
|
||||
callback = function()
|
||||
vim.opt_local.shiftwidth = 2
|
||||
vim.opt_local.tabstop = 2
|
||||
vim.opt_local.expandtab = true
|
||||
vim.api.nvim_create_autocmd("User", {
|
||||
pattern = "TelescopePreviewerLoaded",
|
||||
callback = function(args)
|
||||
local ft = args.data.filetype
|
||||
if vim.tbl_contains({ "lua", "nix", "gleam", "rust" }, ft) then
|
||||
vim.bo.shiftwidth = 2
|
||||
vim.bo.tabstop = 2
|
||||
vim.bo.expandtab = true
|
||||
end
|
||||
end,
|
||||
})
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue