diff --git a/README.md b/README.md index d839edce7..decf582a7 100644 --- a/README.md +++ b/README.md @@ -140,21 +140,15 @@ mkdir -p ~/.config/quickshell/noctalia-shell && curl -sL https://github.com/noct
Nix Installation -You can run Noctalia directly using the `nix run` command: -```bash -nix run github:noctalia-dev/noctalia-shell -``` +You can add it to your NixOS configuration or flake: -Alternatively, you can add it to your NixOS configuration or flake: - -**Step 1**: Add Quickshell and Noctalia flakes to your `flake.nix`: +Add this to your `flake.nix`: ```nix { - description = "Example Nix flake with Noctalia + Quickshell"; + description = "Example Nix flake with Noctalia"; inputs = { nixpkgs.url = "github:nixos/nixpkgs/nixos-unstable"; - # you need nixpkgs unstable quickshell = { url = "github:outfoxxed/quickshell"; @@ -164,31 +158,22 @@ Alternatively, you can add it to your NixOS configuration or flake: noctalia = { url = "github:noctalia-dev/noctalia-shell"; inputs.nixpkgs.follows = "nixpkgs"; - inputs.quickshell.follows = "quickshell"; + inputs.quickshell.follows = "quickshell"; # Use same quickshell version }; }; - outputs = { self, nixpkgs, noctalia, quickshell, ... }: + outputs = { self, nixpkgs, noctalia, ... }: { nixosConfigurations.my-host = nixpkgs.lib.nixosSystem { modules = [ ./configuration.nix + noctalia.nixosModules.noctalia # Import Noctalia module here ]; }; }; } ``` -**Step 2**: Add the packages to your `configuration.nix`: -```nix -{ - environment.systemPackages = with pkgs; [ - inputs.noctalia.packages.${system}.default - inputs.quickshell.packages.${system}.default - ]; -} -``` -
### Usage diff --git a/flake.nix b/flake.nix index 91777a8f2..fb4b4411e 100644 --- a/flake.nix +++ b/flake.nix @@ -80,6 +80,17 @@ }); defaultPackage = eachSystem (system: self.packages.${system}.default); + + nixosModules = { + noctalia = { pkgs, lib, ... }: { + environment.systemPackages = [ + self.packages.${pkgs.system}.default + ]; + # Required services for proper functionality + services.power-profiles-daemon.enable = true; # Power profile switching support + services.upower.enable = true; # Battery monitoring & power management + }; + }; }; }