diff --git a/hosts/archlaptop-vm/default.nix b/hosts/archlaptop-vm/default.nix index 2a20b28..c688815 100644 --- a/hosts/archlaptop-vm/default.nix +++ b/hosts/archlaptop-vm/default.nix @@ -13,6 +13,7 @@ inputs.nixpkgs.lib.nixosSystem { modules = [ inputs.home-manager.nixosModules.home-manager ./hardware-configuration.nix + ../../roles/nixos/graphical-vm.nix ../../modules/hostopts.nix ../../modules/nixos/common.nix ../../modules/nixos/printing.nix @@ -54,11 +55,13 @@ inputs.nixpkgs.lib.nixosSystem { xkb.variant = ""; }; + programs.zsh.enable = true; + environment.shells = with pkgs; [zsh]; # Define a user account. Don't forget to set a password with ‘passwd’. users.users.${config.host.user} = { isNormalUser = true; description = "Gabe Venberg"; - shell = pkgs.nushell; + shell = pkgs.zsh; extraGroups = ["wheel"]; packages = with pkgs; [ firefox @@ -74,10 +77,6 @@ inputs.nixpkgs.lib.nixosSystem { host = osConfig.host; home = { enable-speech = true; - nvim = { - enable-lsp = true; - enable-treesitter = true; - }; git = { profile = { name = "Gabe Venberg"; @@ -87,7 +86,7 @@ inputs.nixpkgs.lib.nixosSystem { }; }; imports = [ - ../../roles/terminal.nix + ../../roles/home-manager/terminal.nix ../../modules/home-manager/nvim ../../modules/home-manager/common.nix ../../modules/home-manager/email.nix diff --git a/hosts/gabe-archlaptop.nix b/hosts/gabe-archlaptop.nix index b6d7bc4..f43c731 100644 --- a/hosts/gabe-archlaptop.nix +++ b/hosts/gabe-archlaptop.nix @@ -34,7 +34,7 @@ inputs.home-manager.lib.homeManagerConfiguration { home.username = "gabe"; home.homeDirectory = /home/gabe; imports = [ - ../roles/terminal.nix + ../roles/home-manager/terminal.nix ../modules/home-manager/nvim ../modules/home-manager/common.nix ../modules/home-manager/syncthing.nix diff --git a/hosts/gabe-gv-workstation.nix b/hosts/gabe-gv-workstation.nix index 1f8add8..4dccacd 100644 --- a/hosts/gabe-gv-workstation.nix +++ b/hosts/gabe-gv-workstation.nix @@ -37,7 +37,7 @@ inputs.home-manager.lib.homeManagerConfiguration { home.username = "gabe"; home.homeDirectory = /home/gabe; imports = [ - ../roles/terminal.nix + ../roles/home-manager/terminal.nix ../modules/home-manager/nvim ../modules/home-manager/common.nix ../modules/home-manager/syncthing.nix diff --git a/hosts/workstation-vm/default.nix b/hosts/workstation-vm/default.nix index 7bb7ae6..919d25f 100644 --- a/hosts/workstation-vm/default.nix +++ b/hosts/workstation-vm/default.nix @@ -13,6 +13,7 @@ inputs.nixpkgs.lib.nixosSystem { modules = [ inputs.home-manager.nixosModules.home-manager ./hardware-configuration.nix + ../../roles/nixos/graphical-vm.nix ../../modules/hostopts.nix ../../modules/nixos/common.nix ../../modules/nixos/printing.nix @@ -54,12 +55,13 @@ inputs.nixpkgs.lib.nixosSystem { xkb.variant = ""; }; - environment.shells = with pkgs; [nushell zsh]; + programs.zsh.enable = true; + environment.shells = with pkgs; [zsh]; # Define a user account. Don't forget to set a password with ‘passwd’. users.users.${config.host.user} = { isNormalUser = true; description = "Gabe Venberg"; - shell = pkgs.nushell; + shell = pkgs.zsh; extraGroups = ["wheel"]; packages = with pkgs; [ firefox @@ -88,7 +90,7 @@ inputs.nixpkgs.lib.nixosSystem { }; }; imports = [ - ../../roles/terminal.nix + ../../roles/home-manager/terminal.nix ../../modules/home-manager/nvim ../../modules/home-manager/common.nix inputs.nixvim.homeManagerModules.nixvim diff --git a/justfile b/justfile index f765370..4a9f07c 100644 --- a/justfile +++ b/justfile @@ -19,3 +19,6 @@ format: home-gc: home-manager expire-generations -7days nix store gc + +nixos-gc: + sudo nix-collect-garbage --delete-older-than 7d diff --git a/modules/both/i3/default.nix b/modules/both/i3/default.nix index 447c519..8e538e8 100644 --- a/modules/both/i3/default.nix +++ b/modules/both/i3/default.nix @@ -25,6 +25,8 @@ home.packages = with pkgs; [ maim brightnessctl + arandr + dex ]; services.playerctld.enable = true; xsession.enable = true; @@ -209,13 +211,18 @@ { command = "betterlockscreen --lock blur"; notification = false; - always = true; + always = false; } { command = "betterlockscreen --wall"; notification = false; always = true; } + { + command = "dex --autostart"; + notification = false; + always = false; + } # { # command = "~/.fehbg"; # notification = false; diff --git a/modules/home-manager/terminal/git.nix b/modules/home-manager/terminal/git.nix index 748972d..ae4ab4e 100644 --- a/modules/home-manager/terminal/git.nix +++ b/modules/home-manager/terminal/git.nix @@ -5,24 +5,22 @@ ... }: { options = { - home = { - git = { - workProfile = { - enable = lib.mkEnableOption "git work profile"; - email = lib.mkOption { - type = lib.types.str; - description = "email for work profile."; - }; + home.git = { + workProfile = { + enable = lib.mkEnableOption "git work profile"; + email = lib.mkOption { + type = lib.types.str; + description = "email for work profile."; }; - profile = { - email = lib.mkOption { - type = lib.types.str; - description = "email for main profile"; - }; - name = lib.mkOption { - type = lib.types.str; - description = "name for main profile"; - }; + }; + profile = { + email = lib.mkOption { + type = lib.types.str; + description = "email for main profile"; + }; + name = lib.mkOption { + type = lib.types.str; + description = "name for main profile"; }; }; }; diff --git a/roles/minimal-terminal.nix b/roles/home-manager/minimal-terminal.nix similarity index 77% rename from roles/minimal-terminal.nix rename to roles/home-manager/minimal-terminal.nix index f64c863..8298f39 100644 --- a/roles/minimal-terminal.nix +++ b/roles/home-manager/minimal-terminal.nix @@ -5,11 +5,11 @@ ... }: { imports = [ - ../modules/home-manager/terminal/zsh.nix - ../modules/home-manager/terminal/git.nix - ../modules/home-manager/terminal/zellij - ../modules/home-manager/terminal/ssh-agent.nix - ../modules/home-manager/terminal/direnv.nix + ../../modules/home-manager/terminal/zsh.nix + ../../modules/home-manager/terminal/git.nix + ../../modules/home-manager/terminal/zellij + ../../modules/home-manager/terminal/ssh-agent.nix + ../../modules/home-manager/terminal/direnv.nix ]; home.packages = with pkgs; [ sshfs diff --git a/roles/terminal.nix b/roles/home-manager/terminal.nix similarity index 73% rename from roles/terminal.nix rename to roles/home-manager/terminal.nix index 0f0f345..c165944 100644 --- a/roles/terminal.nix +++ b/roles/home-manager/terminal.nix @@ -6,10 +6,10 @@ }: { imports = [ ./minimal-terminal.nix - ../modules/home-manager/terminal/nushell - ../modules/home-manager/terminal/starship.nix - ../modules/home-manager/terminal/voice.nix - ../modules/home-manager/terminal/tiny-irc.nix + ../../modules/home-manager/terminal/nushell + ../../modules/home-manager/terminal/starship.nix + ../../modules/home-manager/terminal/voice.nix + ../../modules/home-manager/terminal/tiny-irc.nix ]; home.packages = with pkgs; [ tre-command diff --git a/roles/nixos/graphical-vm.nix b/roles/nixos/graphical-vm.nix new file mode 100644 index 0000000..a1df6aa --- /dev/null +++ b/roles/nixos/graphical-vm.nix @@ -0,0 +1,13 @@ +{ + config, + pkgs, + lib, + ... +}: { + #note: needs to have something that autostarts desktop files. + services.spice-vdagentd.enable = true; + imports = [ + ./vm.nix + ]; + host.gui.enable = true; +} diff --git a/roles/nixos/vm.nix b/roles/nixos/vm.nix new file mode 100644 index 0000000..6d8015c --- /dev/null +++ b/roles/nixos/vm.nix @@ -0,0 +1,10 @@ +{ + config, + pkgs, + lib, + inputs, + ... +}: { + services.qemuGuest.enable = true; + host.isVm = true; +}