added DARWIN

This commit is contained in:
lsoriano-mcm
2025-06-06 06:50:54 -05:00
parent 280a2da2db
commit 6b0a342cdd
2 changed files with 46 additions and 1 deletions
+17 -1
View File
@@ -5,6 +5,8 @@
nixpkgs.url = "github:nixos/nixpkgs?ref=nixos-unstable";
home-manager.url = "github:nix-community/home-manager";
home-manager.inputs.nixpkgs.follows = "nixpkgs"; # `follows` ensure it follows nixpkgs versiona. Avoids breaking updates.
darwin.url = "github:lnl7/nix-darwin";
darwin.inputs.nixpkgs.follows = "nixpkgs";
ags.url = "github:aylur/ags";
ags.inputs.nixpkgs.follows = "nixpkgs";
@@ -25,11 +27,16 @@
outputs = {
nixpkgs,
home-manager,
darwin,
ags,
hyprland,
unlisted-fonts,
nix-neovim,
...
} @ inputs: let
info = import ./info.nix;
lib = nixpkgs.lib;
system = "x86_64-linux";
system = pkgs: pkgs.stdenv.hostPlatform.system;
# pkgs = nixpkgs.legacyPackages.${system}; # alternative, without overlays. Unused.
args =
{
@@ -46,6 +53,15 @@
];
};
};
darwinConfigurations = {
hostname = darwin.lib.darwinSystem {
system = "aarch64-darwin";
modules = [
./nixos/macos/darwin.nix
# home-manager.darwinModules.home-manager
];
};
};
homeConfigurations = {
desktop = home-manager.lib.homeManagerConfiguration {
pkgs = import nixpkgs {
+29
View File
@@ -0,0 +1,29 @@
{pkgs, ...}: {
# List packages installed in system profile. To search by name, run:
# $ nix-env -qaP | grep wget
environment.systemPackages = [pkgs.vim];
# Auto upgrade nix package and the daemon service.
services.nix-daemon.enable = true;
services.karabiner-elements.enable = true;
# nix.package = pkgs.nix;
# Necessary for using flakes on this system.
nix.settings.experimental-features = "nix-command flakes";
# Create /etc/zshrc that loads the nix-darwin environment.
programs.zsh.enable = true; # default shell on catalina
# programs.fish.enable = true;
# Used for backwards compatibility, please read the changelog before changing.
# $ darwin-rebuild changelog
system.stateVersion = 4;
# The platform the configuration will be used on.
nixpkgs.hostPlatform = "aarch64-darwin";
users.users.davish = {
name = "davish";
home = "/Users/davish";
};
}