mirror of
https://github.com/softinio/nix-config.git
synced 2025-09-01 07:06:41 -07:00
initial changes to upgrade to flakes
This commit is contained in:
parent
7194bbdb83
commit
cc0fd60226
4 changed files with 159 additions and 74 deletions
34
flake.nix
Normal file
34
flake.nix
Normal file
|
@ -0,0 +1,34 @@
|
|||
{
|
||||
description = "Nix and home-manager configurations for Softinio's macbook";
|
||||
inputs = {
|
||||
nixpkgs.url = "github:nixos/nixpkgs/nixos-unstable";
|
||||
nur.url = github:nix-community/nur;
|
||||
home-manager = {
|
||||
url = "github:nix-community/home-manager";
|
||||
inputs.nixpkgs.follows = "nixpkgs";
|
||||
};
|
||||
darwin = {
|
||||
url = "github:lnl7/nix-darwin/master";
|
||||
inputs.nixpkgs.follows = "nixpkgs";
|
||||
};
|
||||
};
|
||||
outputs = {darwin, home-manager, nur, nixpkgs, ...}:
|
||||
let
|
||||
homeManagerConfFor = config: { ... }: {
|
||||
nixpkgs.overlays = [ nur.overlay ];
|
||||
imports = [ config ];
|
||||
};
|
||||
darwinSystem = darwin.lib.darwinSystem {
|
||||
system = "x86_64-darwin";
|
||||
modules = [
|
||||
./darwin-configuration.nix
|
||||
home-manager.darwinModules.home-manager {
|
||||
home-manager.users.salar = homeManagerConfFor ./home.nix;
|
||||
}
|
||||
];
|
||||
specialArgs = { inherit nixpkgs; };
|
||||
};
|
||||
in {
|
||||
defaultPackage.x86_64-darwin = darwinSystem.system;
|
||||
};
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue