home: add uid/gid options, correctly configure atuin

This commit is contained in:
Oystein Kristoffer Tveit 2024-11-13 17:04:21 +01:00
parent 84c9562bfc
commit fb6cb3f09d
Signed by: oysteikt
GPG Key ID: 9F2F7D8250F35146
4 changed files with 20 additions and 4 deletions

View File

@ -223,7 +223,11 @@
"specialArgs"
]));
in {
dosei = nixSys "dosei" { };
dosei = nixSys "dosei" {
modules = [{
home-manager.users.h7x4.home.uid = 1001;
}];
};
kasei = nixSys "kasei" { };
europa = nixSys "europa" { };
tsuki = nixSys "tsuki" {

View File

@ -33,6 +33,7 @@ in {
./modules/colors.nix
./modules/shellAliases.nix
./modules/uidGid.nix
] ++ optionals graphics [
./config/gtk.nix

13
home/modules/uidGid.nix Normal file
View File

@ -0,0 +1,13 @@
{ lib, ... }:
{
options.home = {
uid = lib.mkOption {
default = 1000;
type = lib.types.ints.between 0 60000;
};
gid = lib.mkOption {
default = 1000;
type = lib.types.ints.between 0 60000;
};
};
}

View File

@ -1,9 +1,7 @@
{ config, ... }:
let
cfg = config.programs.atuin;
# TODO: retrieve this in a more dynamic and correct manner
xdg_runtime_dir = "/run/user/1000";
xdg_runtime_dir = "/run/user/${toString config.home.uid}";
in
{
programs.atuin = {