[NixOS] Use home manager for vscode support

This commit is contained in:
Ivan Malison 2023-12-13 11:55:20 -07:00
parent b102fd2b85
commit 58b9a395d7
2 changed files with 7 additions and 4 deletions

View File

@ -144,7 +144,7 @@
mkConfig = mkConfig =
args@ args@
{ system ? "x86_64-linux" { system ? "x86_64-linux"
, baseModules ? [inputs.vscode-server.nixosModules.default] , baseModules ? []
, modules ? [] , modules ? []
, specialArgs ? {} , specialArgs ? {}
, ... , ...
@ -156,7 +156,7 @@
inherit inputs machineNames; inherit inputs machineNames;
makeEnable = (import ./make-enable.nix) nixpkgs.lib; makeEnable = (import ./make-enable.nix) nixpkgs.lib;
mapValueToKeys = keys: value: builtins.listToAttrs (map (name: { inherit name value; }) keys); mapValueToKeys = keys: value: builtins.listToAttrs (map (name: { inherit name value; }) keys);
realUsers = [ "root" "imalison" "kat" "dean" "alex" "will" ]; realUsers = [ "root" "imalison" "kat" "dean" "alex" "will" "mike" ];
forEachUser = mapValueToKeys realUsers; forEachUser = mapValueToKeys realUsers;
keys = (import ./keys.nix); keys = (import ./keys.nix);
} // specialArgs; } // specialArgs;

View File

@ -1,4 +1,7 @@
{ config, makeEnable, ... }: { inputs, config, makeEnable, forEachUser, ... }:
makeEnable config "modules.vscode" true { makeEnable config "modules.vscode" true {
services.vscode-server.enable = true; imports = [inputs.vscode-server.homeModules.default];
home-manager.users = forEachUser {
services.vscode-server.enable = true;
};
} }