diff --git a/flake.nix b/flake.nix index 8038171..dbf0527 100644 --- a/flake.nix +++ b/flake.nix @@ -1,5 +1,5 @@ { - description = "Serenity's NixOS configuration"; + description = "SerenityOS v0.2.5"; inputs = { @@ -29,7 +29,7 @@ inputs.nixpkgs.follows = "nixpkgs"; }; hyprpicker.url = "github:hyprwm/hyprpicker"; - # hypr-contrib.url = "github:hyprwm/contrib"; + # hypr-contrib.url = "github:hyprwm/contrib"; }; @@ -49,16 +49,6 @@ config.allowUnfree = true; }; }; - home-manager-config = toplevel: [ - home-manager.nixosModules.home-manager # Home manager go brrrr - { - home-manager.useGlobalPkgs = true; - home-manager.useUserPackages = true; - # home-manager.users.serenity = toplevel; - # Optionally, use home-manager.extraSpecialArgs to pass - # arguments to home.nix - } - ]; overlay-flake-pkgs = final: prev: { }; common-modules = [ @@ -73,8 +63,9 @@ modules = [ ./hosts/proserpina/configuration.nix # Load muir main nix config # nixos-hardware.nixosModules.$MODEL - ] ++ home-manager-config (import ./home/home.nix) ++ common-modules; + ] ++ common-modules; }; }; }; + } diff --git a/modules/core/configuration.nix b/modules/core/configuration.nix index bd5ef20..1130fcb 100755 --- a/modules/core/configuration.nix +++ b/modules/core/configuration.nix @@ -6,27 +6,27 @@ ./modules ]; - nixpkgs.config = { - allowUnfree = true; - permittedInsecurePackages = [ - "schildichat-web-1.11.30-sc.2" - "electron-25.9.0" - "nix-2.15.3" - ]; - }; + # nixpkgs.config = { + # allowUnfree = true; + # permittedInsecurePackages = [ + # "schildichat-web-1.11.30-sc.2" + # "electron-25.9.0" + # "nix-2.15.3" + # ]; + # }; # nix options - nix = { - settings = { - cores = 0; - auto-optimise-store = true; - allowed-users = [ "@wheel" ]; - experimental-features = [ - "nix-command" - "flakes" - ]; - }; - }; + # nix = { + # settings = { + # cores = 0; + # auto-optimise-store = true; + # allowed-users = [ "@wheel" ]; + # experimental-features = [ + # "nix-command" + # "flakes" + # ]; + # }; + # }; system.autoUpgrade = { enable = true; diff --git a/modules/core/display.nix b/modules/core/display.nix new file mode 100644 index 0000000..48b955a --- /dev/null +++ b/modules/core/display.nix @@ -0,0 +1,34 @@ +{ inputs, pkgs, username, ... }: + +{ + + programs.hyprland.enable = true; + xdg.portal = { + enable = true; + wlr.enable = true; + xdgOpenUsePortal = true; + extraPortals = [ + pkgs.xdg-desktop-portal-hyprland + pkgs.xdg-desktop-portal-gtk + ]; + }; + + services.xserver = { + enable = true; + xkb.layout = "us"; + displayManager.autoLogin = { + enable = true; + user = "${USERNAME}"; + }; + libinput = { + enable = true; + # mouse = { + # accelProfile = "flat"; + # }; + }; + }; + + # apparently prevents getting stuck at shutdown + systemd.extraConfig = "DefaultTimeoutStopSec=10s"; + +} diff --git a/modules/core/packages/default.nix b/modules/core/packages/default.nix index 429d163..a80467d 100644 --- a/modules/core/packages/default.nix +++ b/modules/core/packages/default.nix @@ -1,7 +1,52 @@ +{ self, pkgs, lib, inputs, ... }: + { - imports = [ - # ./file.nix + import = [ + ./packages.nix ]; - + + nix = { + settings = { + cores = 0; + auto-optimise-store = true; + allowed-users = [ + "@wheel" + ]; + experimental-features = [ + "nix-command" + "flakes" + ]; + }; + # gc = { + # automatic = true; + # }; + }; + + nixpkgs = { + overlays = [ + self.overlays.default + inputs.nur.overlay + ]; + config = { + allowUnfree = true; + permittedInsecurePackages = [ + "schildichat-web-1.11.30-sc.2" + "electron-25.9.0" + # "nix-2.15.3" + ] + }; + }; + + environment.variables = { + NIXOS_OZONE_WL = "1"; + NIXPKGS_ALLOW_UNFREE = "1"; + PATH = [ + "\${HOME}/.local/bin" + "\${HOME}/.config/rofi/scripts" + ]; + }; + + system.stateVersion = "23.11"; + }