From 3215d522dc3530d79a67a0c37247c43b2e6cc3be Mon Sep 17 00:00:00 2001 From: vali Date: Fri, 12 Apr 2024 14:41:59 +0200 Subject: [PATCH 1/5] added mars, vali's desktop --- hosts/default.nix | 4 ++-- hosts/vali/{ => mars}/configuration.nix | 3 ++- hosts/vali/{ => mars}/default.nix | 0 hosts/vali/{ => mars}/hardware-configuration.nix | 0 hosts/vali/{ => mars}/i3.nix | 2 +- hosts/vali/{ => mars}/profile.nix | 0 hosts/vali/{ => mars}/programs.nix | 0 7 files changed, 5 insertions(+), 4 deletions(-) rename hosts/vali/{ => mars}/configuration.nix (95%) rename hosts/vali/{ => mars}/default.nix (100%) rename hosts/vali/{ => mars}/hardware-configuration.nix (100%) rename hosts/vali/{ => mars}/i3.nix (94%) rename hosts/vali/{ => mars}/profile.nix (100%) rename hosts/vali/{ => mars}/programs.nix (100%) diff --git a/hosts/default.nix b/hosts/default.nix index 0984725..79af885 100644 --- a/hosts/default.nix +++ b/hosts/default.nix @@ -4,11 +4,11 @@ let inherit (self) lib; in { # Vali - vali = lib.nixosSystem { + mars = lib.nixosSystem { system = "x86_64-linux"; specialArgs = { inherit lib inputs self; }; modules = [ - ./vali + ./vali/mars ../modules inputs.home-manager.nixosModules.home-manager inputs.agenix.nixosModules.default diff --git a/hosts/vali/configuration.nix b/hosts/vali/mars/configuration.nix similarity index 95% rename from hosts/vali/configuration.nix rename to hosts/vali/mars/configuration.nix index a0c74e3..f031fe9 100644 --- a/hosts/vali/configuration.nix +++ b/hosts/vali/mars/configuration.nix @@ -9,8 +9,9 @@ myOptions = { other = { system = { - hostname = "nixos"; + hostname = "mars"; username = "vali"; + gitPath = "/home/vali/Git/nichts"; }; home-manager = { enable = true; diff --git a/hosts/vali/default.nix b/hosts/vali/mars/default.nix similarity index 100% rename from hosts/vali/default.nix rename to hosts/vali/mars/default.nix diff --git a/hosts/vali/hardware-configuration.nix b/hosts/vali/mars/hardware-configuration.nix similarity index 100% rename from hosts/vali/hardware-configuration.nix rename to hosts/vali/mars/hardware-configuration.nix diff --git a/hosts/vali/i3.nix b/hosts/vali/mars/i3.nix similarity index 94% rename from hosts/vali/i3.nix rename to hosts/vali/mars/i3.nix index 58b2bfc..8805701 100644 --- a/hosts/vali/i3.nix +++ b/hosts/vali/mars/i3.nix @@ -7,7 +7,7 @@ in { config = mkIf cfg.enable { services.xserver = { enable = true; - layout = "de"; + xkb.layout = "de"; windowManager = { bspwm.enable = true; i3.enable = true; diff --git a/hosts/vali/profile.nix b/hosts/vali/mars/profile.nix similarity index 100% rename from hosts/vali/profile.nix rename to hosts/vali/mars/profile.nix diff --git a/hosts/vali/programs.nix b/hosts/vali/mars/programs.nix similarity index 100% rename from hosts/vali/programs.nix rename to hosts/vali/mars/programs.nix From 558872a8f9f8ea8f3f15603a434a93f99d4e3b2c Mon Sep 17 00:00:00 2001 From: vali Date: Fri, 12 Apr 2024 14:54:23 +0200 Subject: [PATCH 2/5] fixed zsh.nix, fixed mars directory profile --- hosts/vali/mars/profile.nix | 8 ++++---- modules/cli/zsh.nix | 12 ++++++------ 2 files changed, 10 insertions(+), 10 deletions(-) diff --git a/hosts/vali/mars/profile.nix b/hosts/vali/mars/profile.nix index 99a9ac3..ef62882 100644 --- a/hosts/vali/mars/profile.nix +++ b/hosts/vali/mars/profile.nix @@ -1,9 +1,9 @@ _: { imports = [ - ../../options/boot/grub-boot.nix - ../../options/desktop/fonts.nix - ../../options/common/networking.nix - ../../options/common/gpu/nvidia.nix + ../../../options/boot/grub-boot.nix + ../../../options/desktop/fonts.nix + ../../../options/common/networking.nix + ../../../options/common/gpu/nvidia.nix # ../../options/common/pin-registry.nix # ../../options/common/preserve-system.nix #../../options/ diff --git a/modules/cli/zsh.nix b/modules/cli/zsh.nix index 04e90d8..86aec3e 100644 --- a/modules/cli/zsh.nix +++ b/modules/cli/zsh.nix @@ -55,7 +55,7 @@ in { cd = "z"; nv = "nvim"; #TODO fix hardcoding of git repo path and profile name - update = "sudo -p 'password: ' echo 'Your daughter is just a fork of your wife.' && sudo nixos-rebuild switch --flake \"${gitPath}#${config.myOptions.other.system.hostname}\" --log-format internal-json |& nom --json"; + update = "sudo -p 'password: ' echo 'Your daughter is just a fork of your wife.' && sudo nixos-rebuild switch --flake \"${gitPath}#mars\" --log-format internal-json |& nom --json"; } // cfg.extraAliases; initExtraFirst = mkIf cfg.profiling "zmodload zsh/zprof"; @@ -83,11 +83,11 @@ in { }; } ]; - oh-my-zsh = mkIf cfg.oh-my-zsh.enable { - enable = cfg.oh-my-zsh.enable; - theme = cfg.oh-my-zsh.theme; - plugins = cfg.oh-my-zsh.plugins; - }; + oh-my-zsh = mkIf cfg.oh-my-zsh { + enable = cfg.oh-my-zsh.enable; + theme = cfg.oh-my-zsh.theme; + plugins = cfg.oh-my-zsh.plugins; + }; }; }; }; From 1f2131494b6dec772e75bbde773b042ecd51ce28 Mon Sep 17 00:00:00 2001 From: vali Date: Fri, 12 Apr 2024 15:22:33 +0200 Subject: [PATCH 3/5] fixed your horrendous coding layout of oh-my.zsh --- modules/cli/zsh.nix | 34 +++++++++++++++++----------------- 1 file changed, 17 insertions(+), 17 deletions(-) diff --git a/modules/cli/zsh.nix b/modules/cli/zsh.nix index 86aec3e..3b80ce9 100644 --- a/modules/cli/zsh.nix +++ b/modules/cli/zsh.nix @@ -16,19 +16,19 @@ in { description = "enable zsh profiling"; default = false; }; - oh-my-zsh = { - enable = mkEnableOption "oh-my-zsh"; - theme = mkOption { - type = types.str; - description = "oh-my-zsh theme"; - default = "alanpeabody"; - }; - plugins = mkOption { - type = types.listOf(types.str); - description = "oh-my-zsh plugins (like git)"; - default = ["git"]; - }; - }; + ohmyzsh = { + enable = mkEnableOption "ohmyzsh"; + theme = mkOption { + type = types.str; + description = "oh-my-zsh theme"; + default = "alanpeabody"; + }; + plugins = mkOption { + type = types.listOf(types.str); + description = "oh-my-zsh plugins (like git)"; + default = [ git ]; + }; + }; }; config = mkIf cfg.enable { @@ -83,10 +83,10 @@ in { }; } ]; - oh-my-zsh = mkIf cfg.oh-my-zsh { - enable = cfg.oh-my-zsh.enable; - theme = cfg.oh-my-zsh.theme; - plugins = cfg.oh-my-zsh.plugins; + oh-my-zsh = mkIf cfg.ohmyzsh { + enable = true; + theme = cfg.ohmyzsh.theme; + plugins = cfg.ohmyzsh.plugins; }; }; }; From d46a74e403c27ebf1d0e908715b2e9a0b50716ba Mon Sep 17 00:00:00 2001 From: vali Date: Fri, 12 Apr 2024 15:24:35 +0200 Subject: [PATCH 4/5] fixed my error on oh-my-zsh --- modules/cli/zsh.nix | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/modules/cli/zsh.nix b/modules/cli/zsh.nix index 3b80ce9..c2825c6 100644 --- a/modules/cli/zsh.nix +++ b/modules/cli/zsh.nix @@ -83,8 +83,8 @@ in { }; } ]; - oh-my-zsh = mkIf cfg.ohmyzsh { - enable = true; + oh-my-zsh = mkIf cfg.ohmyzsh.enable { + programs.oh-my-zsh.enable = true; theme = cfg.ohmyzsh.theme; plugins = cfg.ohmyzsh.plugins; }; From 4ed45dc9ea641fb90289de1e29e3cdb6e332f34d Mon Sep 17 00:00:00 2001 From: vali Date: Fri, 12 Apr 2024 15:37:27 +0200 Subject: [PATCH 5/5] reenabled xdg, appareantly it does work --- modules/other/default.nix | 2 +- modules/other/xdg.nix | 5 ++--- notes.md | 3 +-- 3 files changed, 4 insertions(+), 6 deletions(-) diff --git a/modules/other/default.nix b/modules/other/default.nix index 477ac1c..7ce8d0e 100644 --- a/modules/other/default.nix +++ b/modules/other/default.nix @@ -2,6 +2,6 @@ _: { imports = [ ./home-manager.nix ./system.nix -# ./xdg.nix + ./xdg.nix ]; } diff --git a/modules/other/xdg.nix b/modules/other/xdg.nix index c69a7f8..c20b7b4 100644 --- a/modules/other/xdg.nix +++ b/modules/other/xdg.nix @@ -14,7 +14,7 @@ text_editor = "nvim.desktop"; in { - environment.sessionVariables = { +/* environment.sessionVariables = { CARGO_HOME = "${hmCfg.xdg.dataHome}/cargo"; GOPATH = "${hmCfg.xdg.dataHome}/go"; GNUPGHOME = "${hmCfg.xdg.dataHome}/gnupg"; @@ -30,14 +30,13 @@ in { WINEPREFIX = "${hmCfg.xdg.dataHome}/wine"; XAUTHORITY = "\$XDG_RUNTIME_DIR/Xauthority"; }; - +*/ myOptions.programs.zsh.extraAliases = { gdb = "gdb -n -x ${hmCfg.xdg.configHome}/gdb/init"; pidgin = "pidgin --config=${hmCfg.xdg.dataHome}/purple"; svn = "svn --config-dir ${hmCfg.xdg.configHome}/subversion"; wget = "wget --hsts-file=\"${hmCfg.xdg.dataHome}/wget-hsts\""; }; - home-manager.users.${username} = { xdg.configFile."npm/npmrc".text = '' prefix=${hmCfg.xdg.dataHome}/npm diff --git a/notes.md b/notes.md index 9b380f5..cc2d0a1 100644 --- a/notes.md +++ b/notes.md @@ -1,2 +1 @@ -## Used Stuff -I think it'd be nice to use flake-parts, they make our config more sane. +# Used Stuff