Skip to content

Commit

Permalink
Streamline linting/formatting/syntax dotenv files
Browse files Browse the repository at this point in the history
  • Loading branch information
Blackjacx committed Aug 22, 2024
1 parent 36fceb4 commit 8b700a8
Show file tree
Hide file tree
Showing 3 changed files with 13 additions and 7 deletions.
13 changes: 7 additions & 6 deletions bootstrap/config_dirs/nvim/lua/user/core/filetypes.lua
Original file line number Diff line number Diff line change
@@ -1,16 +1,17 @@
vim.filetype.add({
extension = {
conf = "conf",
env = "dotenv",
envrc = "dotenv",
env = "sh",
envrc = "sh",
},
filename = {
[".env"] = "dotenv",
[".envrc"] = "dotenv",
[".env"] = "sh",
[".envrc"] = "sh",
["swiftformat"] = "conf",
[".yamlfmt"] = "yaml",
},
pattern = {
["%.env%.[%w_.-]+"] = "dotenv",
["%.envrc%.[%w_.-]+"] = "dotenv",
["%.env%.[%w_.-]+"] = "sh",
["%.envrc%.[%w_.-]+"] = "sh",
},
})
5 changes: 5 additions & 0 deletions bootstrap/config_dirs/nvim/lua/user/plugins/lsp/lspconfig.lua
Original file line number Diff line number Diff line change
Expand Up @@ -92,6 +92,11 @@ return {
["bashls"] = function()
lspconfig["bashls"].setup({
capabilities = capabilities,
filetypes = {
"sh",
"zsh",
"dotenv",
},
})
end,

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,6 @@ return {
local plugin = require("notify")

-- enable
plugin.setup({})
plugin.setup()
end,
}

0 comments on commit 8b700a8

Please sign in to comment.