Skip to content

Commit dfd2b51

Browse files
committed
feat(nvim): add dotenv filetype and make sure .env files are detected as much
1 parent f1baa44 commit dfd2b51

1 file changed

Lines changed: 9 additions & 0 deletions

File tree

modules/nvim.nix

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -29,6 +29,15 @@ with lib;
2929
enable = true;
3030
defaultEditor = true;
3131
extraConfigLuaPre = "if not vim.g.vscode then";
32+
extraConfigLua = # lua
33+
''
34+
vim.filetype.add({
35+
pattern = {
36+
["%.env%..+"] = "dotenv";
37+
["%.env"] = "dotenv";
38+
}
39+
})
40+
'';
3241
extraConfigLuaPost = "end";
3342
viAlias = true;
3443
vimAlias = true;

0 commit comments

Comments
 (0)