nix darwin flake
This commit is contained in:
parent
c29f1a6f0e
commit
1e7f0558db
1 changed files with 73 additions and 0 deletions
73
flake.nix
Normal file
73
flake.nix
Normal file
|
|
@ -0,0 +1,73 @@
|
||||||
|
{
|
||||||
|
description = "Soba MacOS Nix Flake";
|
||||||
|
|
||||||
|
inputs = {
|
||||||
|
nixpkgs.url = "github:NixOS/nixpkgs/nixpkgs-unstable";
|
||||||
|
nix-darwin.url = "github:nix-darwin/nix-darwin/master";
|
||||||
|
nix-darwin.inputs.nixpkgs.follows = "nixpkgs";
|
||||||
|
};
|
||||||
|
|
||||||
|
outputs =
|
||||||
|
inputs@{
|
||||||
|
self,
|
||||||
|
nix-darwin,
|
||||||
|
nixpkgs,
|
||||||
|
}:
|
||||||
|
let
|
||||||
|
configuration =
|
||||||
|
{ pkgs, ... }:
|
||||||
|
{
|
||||||
|
environment.systemPackages = [
|
||||||
|
pkgs.argocd
|
||||||
|
pkgs.fastfetch
|
||||||
|
pkgs.htop
|
||||||
|
pkgs.k9s
|
||||||
|
pkgs.kubectl
|
||||||
|
pkgs.kubectx
|
||||||
|
pkgs.mise
|
||||||
|
pkgs.neovim
|
||||||
|
pkgs.nixd
|
||||||
|
pkgs.nil
|
||||||
|
pkgs.ollama
|
||||||
|
pkgs.vim
|
||||||
|
];
|
||||||
|
|
||||||
|
homebrew = {
|
||||||
|
enable = true;
|
||||||
|
onActivation.cleanup = "zap";
|
||||||
|
onActivation.autoUpdate = true;
|
||||||
|
onActivation.upgrade = true;
|
||||||
|
casks = [
|
||||||
|
"alfred"
|
||||||
|
"firefox"
|
||||||
|
"ghostty"
|
||||||
|
"orbstack"
|
||||||
|
"rectangle"
|
||||||
|
"zed"
|
||||||
|
];
|
||||||
|
};
|
||||||
|
|
||||||
|
nix.settings.experimental-features = "nix-command flakes";
|
||||||
|
nix.gc.automatic = true;
|
||||||
|
nix.optimise.automatic = true;
|
||||||
|
|
||||||
|
system.configurationRevision = self.rev or self.dirtyRev or null;
|
||||||
|
security.pam.services.sudo_local.touchIdAuth = true;
|
||||||
|
|
||||||
|
# Used for backwards compatibility, please read the changelog before changing.
|
||||||
|
# $ darwin-rebuild changelog
|
||||||
|
system.stateVersion = 6;
|
||||||
|
|
||||||
|
system.primaryUser = "soba";
|
||||||
|
|
||||||
|
nixpkgs.hostPlatform = "aarch64-darwin";
|
||||||
|
};
|
||||||
|
in
|
||||||
|
{
|
||||||
|
# Build darwin flake using:
|
||||||
|
# $ darwin-rebuild build --flake .#neptune
|
||||||
|
darwinConfigurations."neptune" = nix-darwin.lib.darwinSystem {
|
||||||
|
modules = [ configuration ];
|
||||||
|
};
|
||||||
|
};
|
||||||
|
}
|
||||||
Loading…
Reference in a new issue