Different username and homeDirectory

This commit is contained in:
xenia 2023-10-19 00:18:10 +02:00
parent b1f126168e
commit 026bd6d77f
2 changed files with 16 additions and 7 deletions

View File

@ -32,12 +32,13 @@
xdg-runtime-dir = "/tmp/xdg-rt"; xdg-runtime-dir = "/tmp/xdg-rt";
mkPkgs = system: import nixpkgs { system = system; config.allowUnfree = true; }; mkPkgs = system: import nixpkgs { system = system; config.allowUnfree = true; };
mkHome = {system, pkgs} : import ./home.nix { mkHome = {username, home-dir, system, pkgs} : import ./home.nix {
inherit username home-dir pkgs xdg-runtime-dir;
kak-pkg = kak.packages.${system}.kak; kak-pkg = kak.packages.${system}.kak;
unispect = unispect.packages.${system}.unispect; unispect = unispect.packages.${system}.unispect;
ansi-utils = ansi-utils.packages.${system}; ansi-utils = ansi-utils.packages.${system};
unambig-path = unambig-path.packages.${system}.unambig-path; unambig-path = unambig-path.packages.${system}.unambig-path;
inherit pkgs xdg-runtime-dir;
}; };
mkLaptop = {system, pkgs} : import ./laptop.nix { mkLaptop = {system, pkgs} : import ./laptop.nix {
inherit pkgs xdg-runtime-dir; inherit pkgs xdg-runtime-dir;
@ -51,7 +52,11 @@
let let
system = "aarch64-darwin"; system = "aarch64-darwin";
pkgs = mkPkgs system; pkgs = mkPkgs system;
home = mkHome { inherit system pkgs; }; home = mkHome {
username = "xenia";
home-dir = "/Users/xenia";
inherit system pkgs;
};
laptop = mkLaptop { inherit system pkgs; }; laptop = mkLaptop { inherit system pkgs; };
mac = mkMac { inherit system pkgs laptop; }; mac = mkMac { inherit system pkgs laptop; };
in home-manager.lib.homeManagerConfiguration { in home-manager.lib.homeManagerConfiguration {
@ -68,7 +73,11 @@
let let
system = "x86_64-linux"; system = "x86_64-linux";
pkgs = mkPkgs system; pkgs = mkPkgs system;
home = mkHome { inherit system pkgs; }; home = mkHome {
username = "coral";
home-dir = "/home/coral";
inherit system pkgs;
};
in home-manager.lib.homeManagerConfiguration { in home-manager.lib.homeManagerConfiguration {
inherit pkgs; inherit pkgs;

View File

@ -1,4 +1,4 @@
{ pkgs, xdg-runtime-dir, kak-pkg, unispect, ansi-utils, unambig-path }: { pkgs, username, home-dir, xdg-runtime-dir, kak-pkg, unispect, ansi-utils, unambig-path }:
let let
kak = import ./kak.nix { kak = kak-pkg; inherit pkgs; }; kak = import ./kak.nix { kak = kak-pkg; inherit pkgs; };
@ -6,8 +6,8 @@ let
extras = import ./extras.nix pkgs; extras = import ./extras.nix pkgs;
in rec { in rec {
home.username = "xenia"; home.username = username;
home.homeDirectory = "/Users/xenia"; home.homeDirectory = home-dir;
home.stateVersion = "23.05"; home.stateVersion = "23.05";