Nix Flakes configuration for MacOS, NixOS and WSL
0
fork

Configure Feed

Select the types of activity you want to include in your feed.

feat: use stable 24.05 instead of unstable

add unstable as an overlay for packages that are not available inside
the stable channel

cosmeak 9cbeb33e bc5ea3db

+74 -51
+29 -11
flake.lock
··· 45 45 ] 46 46 }, 47 47 "locked": { 48 - "lastModified": 1729260213, 49 - "narHash": "sha256-jAvHoU/1y/yCuXzr2fNF+q6uKmr8Jj2xgAisK4QB9to=", 48 + "lastModified": 1726989464, 49 + "narHash": "sha256-Vl+WVTJwutXkimwGprnEtXc/s/s8sMuXzqXaspIGlwM=", 50 50 "owner": "nix-community", 51 51 "repo": "home-manager", 52 - "rev": "09a0c0c02953318bf94425738c7061ffdc4cba75", 52 + "rev": "2f23fa308a7c067e52dfcc30a0758f47043ec176", 53 53 "type": "github" 54 54 }, 55 55 "original": { 56 56 "owner": "nix-community", 57 + "ref": "release-24.05", 57 58 "repo": "home-manager", 58 59 "type": "github" 59 60 } ··· 65 66 "umu": "umu" 66 67 }, 67 68 "locked": { 68 - "lastModified": 1729215603, 69 - "narHash": "sha256-v4fB1nH+pDATpt6Jq/nk+lU2I6Zn3LRF1s4gNPAvZko=", 69 + "lastModified": 1729301900, 70 + "narHash": "sha256-NZ0GGy0OMCVzEsdaqLnefGtXsUnjgoCI2pleIvAUvfI=", 70 71 "owner": "fufexan", 71 72 "repo": "nix-gaming", 72 - "rev": "79f0e311a18bfda913093b4388b24ab380d632d6", 73 + "rev": "5646c9455e9edf9ef59998fc79b82c5d5818ce77", 73 74 "type": "github" 74 75 }, 75 76 "original": { ··· 106 107 "url": "https://github.com/NixOS/nixpkgs/archive/fb192fec7cc7a4c26d51779e9bab07ce6fa5597a.tar.gz" 107 108 } 108 109 }, 110 + "nixpkgs-unstable": { 111 + "locked": { 112 + "lastModified": 1729265718, 113 + "narHash": "sha256-4HQI+6LsO3kpWTYuVGIzhJs1cetFcwT7quWCk/6rqeo=", 114 + "owner": "nixos", 115 + "repo": "nixpkgs", 116 + "rev": "ccc0c2126893dd20963580b6478d1a10a4512185", 117 + "type": "github" 118 + }, 119 + "original": { 120 + "owner": "nixos", 121 + "ref": "nixpkgs-unstable", 122 + "repo": "nixpkgs", 123 + "type": "github" 124 + } 125 + }, 109 126 "nixpkgs_2": { 110 127 "locked": { 111 - "lastModified": 1729070438, 112 - "narHash": "sha256-KOTTUfPkugH52avUvXGxvWy8ibKKj4genodIYUED+Kc=", 128 + "lastModified": 1729181673, 129 + "narHash": "sha256-LDiPhQ3l+fBjRATNtnuDZsBS7hqoBtPkKBkhpoBHv3I=", 113 130 "owner": "nixos", 114 131 "repo": "nixpkgs", 115 - "rev": "5785b6bb5eaae44e627d541023034e1601455827", 132 + "rev": "4eb33fe664af7b41a4c446f87d20c9a0a6321fa3", 116 133 "type": "github" 117 134 }, 118 135 "original": { 119 136 "owner": "nixos", 120 - "ref": "nixos-unstable", 137 + "ref": "nixos-24.05", 121 138 "repo": "nixpkgs", 122 139 "type": "github" 123 140 } ··· 127 144 "darwin": "darwin", 128 145 "home-manager": "home-manager", 129 146 "nix-gaming": "nix-gaming", 130 - "nixpkgs": "nixpkgs_2" 147 + "nixpkgs": "nixpkgs_2", 148 + "nixpkgs-unstable": "nixpkgs-unstable" 131 149 } 132 150 }, 133 151 "umu": {
+22 -4
flake.nix
··· 2 2 description = "Milkyway flakes configurations"; 3 3 4 4 inputs = { 5 - # nixpkgs.url = "github:nixos/nixpkgs/nixos-24.05"; 6 - nixpkgs.url = "github:nixos/nixpkgs/nixos-unstable"; 5 + nixpkgs.url = "github:nixos/nixpkgs/nixos-24.05"; 6 + nixpkgs-unstable.url = "github:nixos/nixpkgs/nixpkgs-unstable"; 7 7 8 8 darwin = { 9 9 url = "github:LnL7/nix-darwin"; ··· 11 11 }; 12 12 13 13 nix-gaming.url = "github:fufexan/nix-gaming"; 14 + 15 + home-manager = { 16 + url = "github:nix-community/home-manager/release-24.05"; 17 + inputs.nixpkgs.follows = "nixpkgs"; 18 + }; 14 19 }; 15 20 16 - outputs = inputs@{ self, nixpkgs, darwin, ... }: 21 + outputs = inputs@{ self, nixpkgs, nixpkgs-unstable, darwin, home-manager, ... }: 17 22 let 18 23 inherit (self) outputs; 19 24 # Currently supported systems ··· 29 34 # Enable formatter 30 35 formatter = forAllSystems (system: nixpkgs.legagyPackages.${system}.alejandra); 31 36 37 + # Applied overlays 38 + overlays = import ./overlays { inherit inputs; }; 39 + 32 40 nixosConfigurations = { 33 41 loki = nixpkgs.lib.nixosSystem { 34 42 specialArgs = { inherit inputs outputs; }; 35 - modules = [ ./hosts/loki/configuration.nix ]; 43 + modules = [ 44 + ./hosts/loki/configuration.nix 45 + home-manager.nixosModules.home-manager 46 + { 47 + home-manager.useGlobalPkgs = true; 48 + home-manager.useUserPackages = true; 49 + home-manager.users = { 50 + cosmeak = import ./homes/cosmeak-loki/home.nix; 51 + }; 52 + } 53 + ]; 36 54 }; 37 55 38 56 nyx = nixpkgs.lib.nixosSystem {
+13
homes/cosmeak-loki/home.nix
··· 1 + { inputs, outputs, pkgs, ... }: 2 + { 3 + home.username = "cosmeak"; 4 + home.homeDirectory = "/home/cosmeak"; 5 + 6 + home.packages = with pkgs; [ 7 + hello 8 + ]; 9 + 10 + # You do not need to change this if you're reading this in the future. 11 + # Don't ever change this after the first build. Don't ask questions. 12 + home.stateVersion = "24.05"; 13 + }
homes/cosmeak@loki/.gitkeep lib/.gitkeep
+3 -2
hosts/loki/configuration.nix
··· 65 65 spotify 66 66 brave 67 67 lutris 68 - zed-editor 68 + unstable.zed-editor 69 69 php83 70 70 php83Packages.composer 71 71 nodejs_20 72 72 lazygit 73 - modrinth-app 73 + unstable.modrinth-app 74 74 btop 75 75 vesktop 76 76 zip ··· 81 81 # Setup nixpkgs rights 82 82 nixpkgs.config.allowUnfree = true; 83 83 nixpkgs.config.allowBroken = true; 84 + nixpkgs.overlays = [ outputs.overlays.unstable-packages ]; 84 85 85 86 # Install packages 86 87 environment.systemPackages = with pkgs; [
-8
modules/nixos/desktops/gnome.nix
··· 1 - { 2 - # Enable the X11 windowing system. 3 - services.xserver.enable = true; 4 - 5 - # Enable the GNOME Desktop Environment. 6 - services.xserver.displayManager.gdm.enable = true; 7 - services.xserver.desktopManager.gnome.enable = true; 8 - }
-9
modules/nixos/desktops/kde-plasma6.nix
··· 1 - { 2 - # Enable the X11 windowing system. 3 - services.xserver.enable = true; 4 - 5 - # Enable KDE Plasma Desktop Environment 6 - services.displayManager.sddm.enable = true; 7 - services.desktopManager.plasma6.enable = true; 8 - services.displayManager.defaultSession = "plasma"; 9 - }
-10
modules/nixos/desktops/xfce.nix
··· 1 - { 2 - #Enable the X11 windowing system. 3 - services.xserver.enable = true; 4 - 5 - # Enable XFCE Desktop Environment 6 - services.xserver.desktopManager.xterm.enable = false; 7 - services.xserver.desktopManager.xfce.enable = true; 8 - 9 - services.displayManager.defaultSession = "xfce"; 10 - }
+7 -7
modules/nixos/graphics/nvidia.nix
··· 1 - { config, ...} : 1 + { config, ...} : 2 2 { 3 3 # Enable OpenGL 4 - hardware.graphics = { 4 + hardware.opengl = { 5 5 enable = true; 6 - # driSupport = true; 7 - enable32Bit = true; 6 + driSupport = true; 7 + driSupport32Bit = true; 8 8 }; 9 9 10 10 services.xserver.videoDrivers = [ "nvidia" ]; 11 - hardware.nvidia = { 11 + hardware.nvidia = { 12 12 package = config.boot.kernelPackages.nvidiaPackages.production; # 550 Driver 13 13 modesetting.enable = true; 14 - powerManagement.enable = false; 14 + powerManagement.enable = false; 15 15 powerManagement.finegrained = false; 16 16 open = false; 17 17 nvidiaSettings = true; 18 18 }; 19 - } 19 + }