diff --git a/.vscode/nixmodule.code-snippets b/.vscode/nixmodule.code-snippets deleted file mode 100644 index 820e939..0000000 --- a/.vscode/nixmodule.code-snippets +++ /dev/null @@ -1,46 +0,0 @@ -{ - // If scope is left empty or omitted, the snippet gets applied to all languages. The prefix is what is - // used to trigger the snippet and the body will be expanded and inserted. Possible variables are: - // $1, $2 for tab stops, $0 for the final cursor position, and ${1:label}, ${2:another} for placeholders. - // Placeholders with the same ids are connected. - "Nix Module with Enable Option": { - "scope": "nix", - "prefix": "nixmodule", - "body": [ - "{ config, lib, pkgs, ... }:", - "let", - " cfg = config.mySystem.${1:moduleName};", - "in", - "{", - " options.mySystem.${1:moduleName} = {", - " enable = lib.mkEnableOption \"${2:Description of the module}\";", - " };", - "", - " config = lib.mkIf cfg.enable {", - " $0", - " };", - "}" - ], - "description": "Creates a blank Nix module with an enable option" - }, - "Nix Home Manager Module with Enable Option": { - "scope": "nix", - "prefix": "nixmodule-homemanager", - "body": [ - "{ config, lib, pkgs, ... }:", - "let", - " cfg = config.myHome.programs.${1:moduleName};", - "in", - "{", - " options.myHome.programs.${1:moduleName} = {", - " enable = lib.mkEnableOption \"${2:Description of the module}\";", - " };", - "", - " config = lib.mkIf cfg.enable {", - " $0", - " };", - "}" - ], - "description": "Creates a blank Nix module with an enable option" - } -} diff --git a/.vscode/settings.json b/.vscode/settings.json index fd7d506..12a72bf 100644 --- a/.vscode/settings.json +++ b/.vscode/settings.json @@ -9,7 +9,7 @@ "editor.guides.bracketPairsHorizontal": true, "editor.guides.highlightActiveBracketPair": true, "files.trimTrailingWhitespace": true, - "sops.defaults.ageKeyFile": "/home/jahanson/projects/mochi/age.key", + "sops.defaults.ageKeyFile": "age.key", "nix.enableLanguageServer": true, "nix.serverPath": "/run/current-system/sw/bin/nil", "nix.formatterPath": "/run/current-system/sw/bin/nixfmt", @@ -36,5 +36,6 @@ "[jsonc]": { "editor.defaultFormatter": "esbenp.prettier-vscode" }, - "sops.binPath": "/run/current-system/sw/bin/sops" + "sops.binPath": "/run/current-system/sw/bin/sops", + "editor.formatOnSave": true }