Home : Create Default config and add Dasha and Root HM.
This commit is contained in:
parent
8e390c8ff2
commit
86eafdbeba
|
@ -127,7 +127,6 @@
|
|||
./module/common/Nix.nix
|
||||
./module/common/Nvim.nix
|
||||
./module/common/Package.nix
|
||||
./module/common/Root.nix
|
||||
./module/common/Ssh.nix
|
||||
./module/common/Sshd.nix
|
||||
./module/common/Swap.nix
|
||||
|
@ -135,6 +134,7 @@
|
|||
./module/common/Users.nix
|
||||
./module/common/Wallpaper.nix
|
||||
./module/common/YtDlp.nix
|
||||
./user/Root.nix
|
||||
];
|
||||
|
||||
# Function to create a host.
|
||||
|
|
|
@ -1,4 +1,7 @@
|
|||
{ pkgs, lib, ... }: {
|
||||
imports = [
|
||||
./home/Dasha.nix
|
||||
];
|
||||
users.users.dasha = {
|
||||
hashedPassword = "$y$j9T$WGMPv/bRhGBUidcZLZ7CE/$raZhwFFdI/XvegVZVHLILJLMiBkOxSErc6gao/Cxt33"; # Use `mkpasswd`.
|
||||
uid = 1001;
|
||||
|
|
|
@ -1,4 +1,7 @@
|
|||
{ const, ... }: {
|
||||
imports = [
|
||||
./home/Root.nix
|
||||
];
|
||||
users.users.root.hashedPassword = const.hashedPassword;
|
||||
security.sudo = {
|
||||
enable = false;
|
9
user/home/Dasha.nix
Normal file
9
user/home/Dasha.nix
Normal file
|
@ -0,0 +1,9 @@
|
|||
{ const, ... }: {
|
||||
imports = [
|
||||
(import ./Default.nix {
|
||||
const = const;
|
||||
username = "dasha";
|
||||
homeDir = "/home/dasha";
|
||||
})
|
||||
];
|
||||
}
|
39
user/home/Default.nix
Normal file
39
user/home/Default.nix
Normal file
|
@ -0,0 +1,39 @@
|
|||
{ const, username, homeDir, ... }: {
|
||||
home-manager.users.${username} = {
|
||||
programs.home-manager.enable = true;
|
||||
home.username = username;
|
||||
home.homeDirectory = homeDir;
|
||||
home.stateVersion = const.stateVersion;
|
||||
|
||||
home.file = {
|
||||
".config/btop".source = ./module/top/btop;
|
||||
".config/gtk-2.0".source = ./module/gtk/2;
|
||||
".config/gtk-3.0".source = ./module/gtk/3;
|
||||
".config/gtk-4.0".source = ./module/gtk/4;
|
||||
".config/htop".source = ./module/top/htop;
|
||||
".editorconfig".source = ./module/Editorconfig;
|
||||
".parallel/will-cite".text = "";
|
||||
"app/bin".source = ./module/bin;
|
||||
"media/template".source = ./module/template;
|
||||
};
|
||||
|
||||
# Directories.
|
||||
xdg.userDirs = {
|
||||
enable = true;
|
||||
createDirectories = true;
|
||||
desktop = "${homeDir}/";
|
||||
documents = "${homeDir}/document/";
|
||||
download = "${homeDir}/download/";
|
||||
music = "${homeDir}/media/music/";
|
||||
pictures = "${homeDir}/media/picture/";
|
||||
publicShare = "${homeDir}/media/share/";
|
||||
templates = "${homeDir}/media/template/";
|
||||
videos = "${homeDir}/media/video/";
|
||||
extraConfig = {
|
||||
XDG_APP_DIR = "${homeDir}/app/";
|
||||
XDG_TMP_DIR = "${homeDir}/tmp/";
|
||||
};
|
||||
};
|
||||
};
|
||||
}
|
||||
|
9
user/home/Root.nix
Normal file
9
user/home/Root.nix
Normal file
|
@ -0,0 +1,9 @@
|
|||
{ const, ... }: {
|
||||
imports = [
|
||||
(import ./Default.nix {
|
||||
const = const;
|
||||
username = "root";
|
||||
homeDir = "/root";
|
||||
})
|
||||
];
|
||||
}
|
|
@ -1,41 +1,9 @@
|
|||
{ const, ... }: let
|
||||
{ const, ... }: {
|
||||
imports = [
|
||||
(import ./Default.nix {
|
||||
const = const;
|
||||
username = "voronind";
|
||||
homeDir = "/home/voronind";
|
||||
in {
|
||||
home-manager.users.voronind = {
|
||||
programs.home-manager.enable = true;
|
||||
home.username = username;
|
||||
home.homeDirectory = homeDir;
|
||||
home.stateVersion = const.stateVersion;
|
||||
|
||||
home.file = {
|
||||
".config/btop".source = ./module/top/btop;
|
||||
".config/gtk-2.0".source = ./module/gtk/2;
|
||||
".config/gtk-3.0".source = ./module/gtk/3;
|
||||
".config/gtk-4.0".source = ./module/gtk/4;
|
||||
".config/htop".source = ./module/top/htop;
|
||||
".editorconfig".source = ./module/Editorconfig;
|
||||
".parallel/will-cite".text = "";
|
||||
"app/bin".source = ./module/bin;
|
||||
"media/template".source = ./module/template;
|
||||
};
|
||||
|
||||
# Directories.
|
||||
xdg.userDirs = {
|
||||
enable = true;
|
||||
createDirectories = true;
|
||||
desktop = "${homeDir}/";
|
||||
documents = "${homeDir}/document/";
|
||||
download = "${homeDir}/download/";
|
||||
music = "${homeDir}/media/music/";
|
||||
pictures = "${homeDir}/media/picture/";
|
||||
publicShare = "${homeDir}/media/share/";
|
||||
templates = "${homeDir}/media/template/";
|
||||
videos = "${homeDir}/media/video/";
|
||||
extraConfig = {
|
||||
XDG_APP_DIR = "${homeDir}/app/";
|
||||
XDG_TMP_DIR = "${homeDir}/tmp/";
|
||||
};
|
||||
};
|
||||
};
|
||||
})
|
||||
];
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue