50 lines
1.2 KiB
Nix
50 lines
1.2 KiB
Nix
{
|
|
description = "Nix Darwin Configuration";
|
|
inputs = {
|
|
# monorepo w/ recipes ("derivations")
|
|
nixpkgs.url = "github:nixos/nixpkgs/nixpkgs-unstable";
|
|
|
|
# manages configs
|
|
home-manager.url = "github:nix-community/home-manager/master";
|
|
home-manager.inputs.nixpkgs.follows = "nixpkgs";
|
|
|
|
# system-level software and settings (macOS)
|
|
darwin.url = "github:lnl7/nix-darwin";
|
|
darwin.inputs.nixpkgs.follows = "nixpkgs";
|
|
|
|
# declarative homebrew management
|
|
nix-homebrew.url = "github:zhaofengli/nix-homebrew";
|
|
|
|
# declarative Neovim
|
|
nixvim.url = "github:nix-community/nixvim";
|
|
};
|
|
|
|
outputs =
|
|
{
|
|
self,
|
|
darwin,
|
|
nixpkgs,
|
|
home-manager,
|
|
nix-homebrew,
|
|
nixvim,
|
|
...
|
|
}@inputs:
|
|
let
|
|
# TODO: replace with your username
|
|
primaryUser = "phil";
|
|
in
|
|
{
|
|
# build darwin flake using:
|
|
# $ darwin-rebuild build --flake .#<name>
|
|
darwinConfigurations."cyper-mac" = darwin.lib.darwinSystem {
|
|
system = "x86_64-darwin"; # aarch64-darwin
|
|
modules = [
|
|
./darwin
|
|
./hosts/cyper-mac/configuration.nix
|
|
];
|
|
specialArgs = { inherit inputs self primaryUser; };
|
|
};
|
|
|
|
};
|
|
}
|