dotfiles/modules/vscode.nix

33 lines
883 B
Nix
Raw Normal View History

2023-02-10 07:46:37 +01:00
{
config,
flakePath,
lib,
pkgs,
...
}: let
inherit (pkgs.stdenv.hostPlatform) isLinux;
inherit (pkgs.stdenv.hostPlatform) isDarwin;
2023-02-10 07:46:37 +01:00
in {
programs.vscode = {
enable = true;
extensions = with pkgs.vscode-extensions; [
pkgs.nur.repos.nekowinston.vscode-extensions.ms-kubernetes-tools.vscode-kubernetes-tools
pkief.material-icon-theme
redhat.vscode-yaml
valentjn.vscode-ltex
vscodevim.vim
];
mutableExtensionsDir = true;
};
home.file = {
"${config.xdg.configHome}/Code/User/settings.json" = {
enable = isLinux;
2023-02-10 06:34:05 +01:00
source = config.lib.file.mkOutOfStoreSymlink "${flakePath}/modules/vscode/settings.json";
};
"Library/Application Support/Code/User/settings.json" = {
enable = isDarwin;
2023-02-10 06:34:05 +01:00
source = config.lib.file.mkOutOfStoreSymlink "${flakePath}/modules/vscode/settings.json";
};
};
}