Compare commits

..
5 Commits
5 changed files with 86 additions and 30 deletions
Generated
+42 -21
View File
@@ -67,11 +67,11 @@
"systems": "systems_2" "systems": "systems_2"
}, },
"locked": { "locked": {
"lastModified": 1788552094, "lastModified": 1789074092,
"narHash": "sha256-fdD1tF+RjJME8DRMI/dz2lBuFQ8SvyPCF8tVVZ02OvQ=", "narHash": "sha256-QCXTUbd4FuwOHO7LgJws78YTRcco4xgR8RoYgKLvd9w=",
"owner": "sadjow", "owner": "sadjow",
"repo": "claude-code-nix", "repo": "claude-code-nix",
"rev": "ac5abfc00fe9226e9d116f8e2fbb69ae26775ea3", "rev": "1f88b393ac054378c393f914dc83d08a6ef5daeb",
"type": "github" "type": "github"
}, },
"original": { "original": {
@@ -242,11 +242,11 @@
] ]
}, },
"locked": { "locked": {
"lastModified": 1788644970, "lastModified": 1789071706,
"narHash": "sha256-6BI+HCRmDPcdoudp7VvLKGBiRhiDct+4MARCxDFI3jg=", "narHash": "sha256-S+oyh2YSP9V5bSjWbbK0N7GxdxxMwgBfUOtUdVcAWc4=",
"owner": "nix-community", "owner": "nix-community",
"repo": "home-manager", "repo": "home-manager",
"rev": "11f7a2df92b132274c49d2645cacd375d4345cf4", "rev": "150f9ce4ddd41544ea42eb9d6043a75bd615fa24",
"type": "github" "type": "github"
}, },
"original": { "original": {
@@ -256,6 +256,26 @@
"type": "github" "type": "github"
} }
}, },
"homebrew": {
"inputs": {
"nixpkgs": [
"nixpkgs"
]
},
"locked": {
"lastModified": 1785271058,
"narHash": "sha256-xVisL04Gt6LsGa1cGCLHhTED7iEykgl7krPyzAm2ZQg=",
"owner": "koalalorenzo",
"repo": "home-manager-brew",
"rev": "795f9aed8ddce24b3cae3b75598e6861e7d72d10",
"type": "github"
},
"original": {
"owner": "koalalorenzo",
"repo": "home-manager-brew",
"type": "github"
}
},
"lanzaboote": { "lanzaboote": {
"inputs": { "inputs": {
"crane": "crane", "crane": "crane",
@@ -287,11 +307,11 @@
"nixpkgs": "nixpkgs" "nixpkgs": "nixpkgs"
}, },
"locked": { "locked": {
"lastModified": 1788636383, "lastModified": 1789070668,
"narHash": "sha256-rb0Cq4ahQej8/d4qMyZJ9nqfjNUptNUzhoc3OXUzYWc=", "narHash": "sha256-Zel41jsQnKlZQHBFndBoRCJ3WfJCXknV2jL0GJbLy9k=",
"owner": "xddxdd", "owner": "xddxdd",
"repo": "nix-cachyos-kernel", "repo": "nix-cachyos-kernel",
"rev": "aa89b450a7ba56db6f5f7331672404dae7e0805f", "rev": "b8538a38adfd2a443aa0f8f3d506c29161f71f5f",
"type": "github" "type": "github"
}, },
"original": { "original": {
@@ -344,11 +364,11 @@
] ]
}, },
"locked": { "locked": {
"lastModified": 1788635631, "lastModified": 1789063032,
"narHash": "sha256-j1HgbzMxAi/W2ezt2We3DuDNyuZaWXS/Pwg33D/cmQk=", "narHash": "sha256-QHJcFCNEf7gqOzwClCIyAnU24Q2OUQS9WJTduZgnkxs=",
"owner": "sudosubin", "owner": "sudosubin",
"repo": "nix-skills", "repo": "nix-skills",
"rev": "6779edbf5b00060920e638197d076d1eb0bdadda", "rev": "f3305681ea01e147fc65fa16d55df81fab28c6f7",
"type": "github" "type": "github"
}, },
"original": { "original": {
@@ -387,11 +407,11 @@
] ]
}, },
"locked": { "locked": {
"lastModified": 1788335262, "lastModified": 1788942796,
"narHash": "sha256-3jBEq8avfzlrsY4UpW4d5TOmm7ocseZfnitEJhqauyc=", "narHash": "sha256-CLoJCCRi9sogsyGXYn8rOCWBLKAntfKUB9Rli/YXgEY=",
"owner": "NixOS", "owner": "NixOS",
"repo": "nixos-hardware", "repo": "nixos-hardware",
"rev": "44d95795ee2d475b3d687325e26dcf4ca9104557", "rev": "83bbc895120516d6e86885a188c04beced6535d9",
"type": "github" "type": "github"
}, },
"original": { "original": {
@@ -403,11 +423,11 @@
}, },
"nixpkgs": { "nixpkgs": {
"locked": { "locked": {
"lastModified": 1788625351, "lastModified": 1789034407,
"narHash": "sha256-HuowOcoS6Wquoa0FPdCwRZ9NkXy3kw+gz0gV2sKhBW8=", "narHash": "sha256-7X4GZ0KK5qHF9lppR9IlfXShYGcxxw1Kcjj8m5+19H0=",
"owner": "NixOS", "owner": "NixOS",
"repo": "nixpkgs", "repo": "nixpkgs",
"rev": "8f3889588add43913e8bfbbd42a75345c857cf59", "rev": "3824e02a19d7dccf95c30aa1cab8c857323d2201",
"type": "github" "type": "github"
}, },
"original": { "original": {
@@ -450,11 +470,11 @@
}, },
"nixpkgs_2": { "nixpkgs_2": {
"locked": { "locked": {
"lastModified": 1788614874, "lastModified": 1789006805,
"narHash": "sha256-7QYjT2vHLuX9Z1pdxHXDKCbh1CR3D/2rywB9Tx0MPRg=", "narHash": "sha256-xB8mKMOx1IA9vTDNLmJZ6n4wCMq/cuWBBOzGCRnqxrU=",
"owner": "NixOS", "owner": "NixOS",
"repo": "nixpkgs", "repo": "nixpkgs",
"rev": "c043004d1c6985732bcc1cbc5a9c9aecbbb4e0f0", "rev": "8ce4ef6cb6f871616146b9fe26d2a5ae594e94fe",
"type": "github" "type": "github"
}, },
"original": { "original": {
@@ -551,6 +571,7 @@
"bun2nix": "bun2nix", "bun2nix": "bun2nix",
"claude-code": "claude-code", "claude-code": "claude-code",
"home-manager": "home-manager", "home-manager": "home-manager",
"homebrew": "homebrew",
"lanzaboote": "lanzaboote", "lanzaboote": "lanzaboote",
"nix-cachyos-kernel": "nix-cachyos-kernel", "nix-cachyos-kernel": "nix-cachyos-kernel",
"nix-darwin": "nix-darwin", "nix-darwin": "nix-darwin",
+6 -1
View File
@@ -61,6 +61,10 @@
url = "github:nix-darwin/nix-darwin/master"; url = "github:nix-darwin/nix-darwin/master";
inputs.nixpkgs.follows = "nixpkgs"; inputs.nixpkgs.follows = "nixpkgs";
}; };
homebrew = {
url = "github:koalalorenzo/home-manager-brew";
inputs.nixpkgs.follows = "nixpkgs";
};
}; };
outputs = { self, nixos-hardware, nix-darwin, ... }@inputs: outputs = { self, nixos-hardware, nix-darwin, ... }@inputs:
@@ -76,7 +80,7 @@
}; };
darwinConfigurations."MacBook-Pro-Macbook" = nix-darwin.lib.darwinSystem { darwinConfigurations."MacBook-Pro-Macbook" = nix-darwin.lib.darwinSystem {
modules = [ modules = [
((import ./configuration.nix) self) ((import ./hosts/macbook.nix) self)
inputs.home-manager.darwinModules.home-manager inputs.home-manager.darwinModules.home-manager
{ {
home-manager.useGlobalPkgs = true; home-manager.useGlobalPkgs = true;
@@ -86,6 +90,7 @@
imports = [ imports = [
./home-modules ./home-modules
./users/user/home.nix ./users/user/home.nix
inputs.homebrew.homeManagerModules.default
]; ];
lumpiastyHome.macos = true; lumpiastyHome.macos = true;
}; };
+6 -1
View File
@@ -1,6 +1,8 @@
{ flake, pkgs, lib, osConfig ? null, ... }: { flake, pkgs, lib, osConfig ? null, ... }:
{ {
options.lumpiastyHome.macos = lib.mkEnableOption "Macos specific things";
imports = [ imports = [
./gpg.nix ./gpg.nix
./pc.nix ./pc.nix
@@ -8,8 +10,11 @@
./gaming.nix ./gaming.nix
./fhsBash.nix ./fhsBash.nix
./linux.nix ./linux.nix
] ++ lib.optionals (osConfig ? system.defaults) [
# Can't use config.lumpiastyHome.macos here — imports are evaluated before config,
# causing infinite recursion. osConfig ? system.defaults detects nix-darwin.
./macos.nix ./macos.nix
] ++ lib.optionals (osConfig.lumpiasty.enablePlasma) [ ] ++ lib.optionals (osConfig.lumpiasty.enablePlasma) [
./plasma.nix ./plasma.nix
]; ];
} }
+27 -4
View File
@@ -1,10 +1,33 @@
{ config, lib, pkgs, osConfig, ... }: { config, lib, pkgs, osConfig, ... }:
{ let
options.lumpiastyHome.macos = lib.mkEnableOption "Macos specific things"; brewPath = config.homebrew.brewPath;
in {
config = lib.mkIf config.lumpiastyHome.macos { config = lib.mkIf config.lumpiastyHome.macos {
targets.darwin.copyApps.enable = true; targets.darwin.copyApps.enable = true;
targets.darwin.linkApps.enable = false; targets.darwin.linkApps.enable = false;
homebrew = {
enable = true;
brewInstall = true;
update = true;
upgrade = true;
cleanup = true;
casks = [
"steam"
];
};
home.activation.homebrewInstall = lib.mkForce (
lib.hm.dag.entryAfter ["installPackages" "linkGeneration" "createGpgHomedir"] (
if config.homebrew.brewInstall then ''
if [ ! -f "${brewPath}" ]; then
echo "Homebrew not found (${brewPath}), installing..."
export PATH="${pkgs.curl}/bin:${pkgs.bash}/bin:${pkgs.coreutils}/bin:${pkgs.gnugrep}/bin:${pkgs.gnused}/bin:$PATH"
${pkgs.bash}/bin/bash -c "$(${pkgs.curl}/bin/curl -fsSL https://raw.githubusercontent.com/Homebrew/install/HEAD/install.sh)"
fi
'' else ""
)
);
}; };
} }
+5 -3
View File
@@ -1,10 +1,12 @@
self: { pkgs, ... }: { self: { pkgs, ... }: {
imports = [ ./modules/options.nix ]; imports = [ ../modules/options.nix ];
# List packages installed in system profile. To search by name, run: # List packages installed in system profile. To search by name, run:
# $ nix-env -qaP | grep wget # $ nix-env -qaP | grep wget
environment.systemPackages = environment.systemPackages = with pkgs; [
[ pkgs.vim vim
curl
git
]; ];
# Necessary for using flakes on this system. # Necessary for using flakes on this system.