update flake

This commit is contained in:
Yan Lin 2026-02-10 07:52:59 +01:00
parent 8a9a05df16
commit d534880860
5 changed files with 20 additions and 177 deletions

141
flake.lock generated
View file

@ -17,25 +17,6 @@
"type": "github"
}
},
"claude-code": {
"inputs": {
"flake-utils": "flake-utils",
"nixpkgs": "nixpkgs"
},
"locked": {
"lastModified": 1770362224,
"narHash": "sha256-glZjGWSy+LpalbwlsQ3iWNpWU4TlEOandYWOpl8sMt8=",
"owner": "sadjow",
"repo": "claude-code-nix",
"rev": "f4f8d6e7cc59e34e5a85550f017ead83ab925b22",
"type": "github"
},
"original": {
"owner": "sadjow",
"repo": "claude-code-nix",
"type": "github"
}
},
"disko": {
"inputs": {
"nixpkgs": [
@ -64,11 +45,11 @@
},
"locked": {
"dir": "pkgs/firefox-addons",
"lastModified": 1770350627,
"narHash": "sha256-gaLX5akNsppWTRPw4Q+E8QxsjxMkMAU539wFdnI8i70=",
"lastModified": 1770609827,
"narHash": "sha256-5J3I/ERia1xhWkPwugnpbucAE8lI5ip2ohTZ3xK2HrY=",
"owner": "rycee",
"repo": "nur-expressions",
"rev": "27854a8a99d8ef77d0d6c70cf9c7f99f1a3e8d8f",
"rev": "60b2a2d7633b61981a694ad30bc1b19b64a949f1",
"type": "gitlab"
},
"original": {
@ -99,24 +80,6 @@
"type": "github"
}
},
"flake-utils": {
"inputs": {
"systems": "systems"
},
"locked": {
"lastModified": 1731533236,
"narHash": "sha256-l0KFg5HjrsfsO/JpG+r7fRrqm12kzFHyUHqHCVpMMbI=",
"owner": "numtide",
"repo": "flake-utils",
"rev": "11707dc2f618dd54ca8739b309ec4fc024de578b",
"type": "github"
},
"original": {
"owner": "numtide",
"repo": "flake-utils",
"type": "github"
}
},
"home-manager": {
"inputs": {
"nixpkgs": [
@ -124,11 +87,11 @@
]
},
"locked": {
"lastModified": 1770318660,
"narHash": "sha256-yFVde8QZK7Dc0Xa8eQDsmxLX4NJNfL1NKfctSyiQgMY=",
"lastModified": 1770654520,
"narHash": "sha256-mg5WZMIPGsFu9MxSrUcuJUPMbfMsF77el5yb/7rc10k=",
"owner": "nix-community",
"repo": "home-manager",
"rev": "471e6a065f9efed51488d7c51a9abbd387df91b8",
"rev": "6c4fdbe1ad198fac36c320fd45c5957324a80b8e",
"type": "github"
},
"original": {
@ -137,27 +100,6 @@
"type": "github"
}
},
"jovian": {
"inputs": {
"nix-github-actions": "nix-github-actions",
"nixpkgs": [
"nixpkgs"
]
},
"locked": {
"lastModified": 1770366813,
"narHash": "sha256-q6dmMSV2EcA6/EXy2oJXoLgxSGjrKY0bixfYbK4fi/4=",
"owner": "Jovian-Experiments",
"repo": "Jovian-NixOS",
"rev": "2af374cd694b45c7d1773edda154081d0ee81f64",
"type": "github"
},
"original": {
"owner": "Jovian-Experiments",
"repo": "Jovian-NixOS",
"type": "github"
}
},
"nix-darwin": {
"inputs": {
"nixpkgs": [
@ -179,28 +121,6 @@
"type": "github"
}
},
"nix-github-actions": {
"inputs": {
"nixpkgs": [
"jovian",
"nixpkgs"
]
},
"locked": {
"lastModified": 1729697500,
"narHash": "sha256-VFTWrbzDlZyFHHb1AlKRiD/qqCJIripXKiCSFS8fAOY=",
"owner": "zhaofengli",
"repo": "nix-github-actions",
"rev": "e418aeb728b6aa5ca8c5c71974e7159c2df1d8cf",
"type": "github"
},
"original": {
"owner": "zhaofengli",
"ref": "matrix-name",
"repo": "nix-github-actions",
"type": "github"
}
},
"nix-homebrew": {
"inputs": {
"brew-src": "brew-src"
@ -221,27 +141,11 @@
},
"nixpkgs": {
"locked": {
"lastModified": 1770169770,
"narHash": "sha256-awR8qIwJxJJiOmcEGgP2KUqYmHG4v/z8XpL9z8FnT1A=",
"lastModified": 1770537093,
"narHash": "sha256-pF1quXG5wsgtyuPOHcLfYg/ft/QMr8NnX0i6tW2187s=",
"owner": "NixOS",
"repo": "nixpkgs",
"rev": "aa290c9891fa4ebe88f8889e59633d20cc06a5f2",
"type": "github"
},
"original": {
"owner": "NixOS",
"ref": "nixpkgs-unstable",
"repo": "nixpkgs",
"type": "github"
}
},
"nixpkgs_2": {
"locked": {
"lastModified": 1770169770,
"narHash": "sha256-awR8qIwJxJJiOmcEGgP2KUqYmHG4v/z8XpL9z8FnT1A=",
"owner": "NixOS",
"repo": "nixpkgs",
"rev": "aa290c9891fa4ebe88f8889e59633d20cc06a5f2",
"rev": "fef9403a3e4d31b0a23f0bacebbec52c248fbb51",
"type": "github"
},
"original": {
@ -257,14 +161,14 @@
"nixpkgs": [
"nixpkgs"
],
"systems": "systems_2"
"systems": "systems"
},
"locked": {
"lastModified": 1770388595,
"narHash": "sha256-0NvpmDqFcJAtRFJE3RDZWnN7PDJBZutoDtN+Cl8a3DY=",
"lastModified": 1770630823,
"narHash": "sha256-5SEmOnJ61vmbap39vzWEsCX5UQ+3Ul8J4mXWKdqSn3w=",
"owner": "nix-community",
"repo": "nixvim",
"rev": "51abc532525e486176f9a7b24b17908c60017b54",
"rev": "6acc964664ac916c64fe4e394edd467af4d90790",
"type": "github"
},
"original": {
@ -275,14 +179,12 @@
},
"root": {
"inputs": {
"claude-code": "claude-code",
"disko": "disko",
"firefox-addons": "firefox-addons",
"home-manager": "home-manager",
"jovian": "jovian",
"nix-darwin": "nix-darwin",
"nix-homebrew": "nix-homebrew",
"nixpkgs": "nixpkgs_2",
"nixpkgs": "nixpkgs",
"nixvim": "nixvim"
}
},
@ -300,21 +202,6 @@
"repo": "default",
"type": "github"
}
},
"systems_2": {
"locked": {
"lastModified": 1681028828,
"narHash": "sha256-Vy1rq5AaRuLzOxct8nz4T6wlgyUR7zLU309k9mBC768=",
"owner": "nix-systems",
"repo": "default",
"rev": "da67096a3b9bf56a91d16901293e51ba5b49a27e",
"type": "github"
},
"original": {
"owner": "nix-systems",
"repo": "default",
"type": "github"
}
}
},
"root": "root",

View file

@ -9,7 +9,6 @@
home-manager.inputs.nixpkgs.follows = "nixpkgs";
nixvim.url = "github:nix-community/nixvim";
nixvim.inputs.nixpkgs.follows = "nixpkgs";
claude-code.url = "github:sadjow/claude-code-nix";
firefox-addons = {
url = "gitlab:rycee/nur-expressions?dir=pkgs/firefox-addons";
inputs.nixpkgs.follows = "nixpkgs";
@ -17,11 +16,9 @@
nix-homebrew.url = "github:zhaofengli/nix-homebrew";
disko.url = "github:nix-community/disko";
disko.inputs.nixpkgs.follows = "nixpkgs";
jovian.url = "github:Jovian-Experiments/Jovian-NixOS";
jovian.inputs.nixpkgs.follows = "nixpkgs";
};
outputs = inputs@{ self, nix-darwin, nixpkgs, home-manager, nixvim, claude-code, firefox-addons, nix-homebrew, disko, jovian }:
outputs = inputs@{ self, nix-darwin, nixpkgs, home-manager, nixvim, firefox-addons, nix-homebrew, disko }:
{
darwinConfigurations."macbook" = nix-darwin.lib.darwinSystem {
modules = [
@ -64,27 +61,17 @@
];
};
nixosConfigurations."deck" = nixpkgs.lib.nixosSystem {
system = "x86_64-linux";
modules = [
jovian.nixosModules.default
disko.nixosModules.disko
./hosts/nixos/deck/system.nix
./hosts/nixos/deck/disk-config.nix
];
};
homeConfigurations = {
"yanlin@macbook" = home-manager.lib.homeManagerConfiguration {
pkgs = nixpkgs.legacyPackages.aarch64-darwin;
modules = [ ./hosts/darwin/macbook/home.nix ];
extraSpecialArgs = { inherit claude-code nixvim firefox-addons; };
extraSpecialArgs = { inherit nixvim firefox-addons; };
};
"yanlin@imac" = home-manager.lib.homeManagerConfiguration {
pkgs = nixpkgs.legacyPackages.aarch64-darwin;
modules = [ ./hosts/darwin/imac/home.nix ];
extraSpecialArgs = { inherit claude-code nixvim firefox-addons; };
extraSpecialArgs = { inherit nixvim firefox-addons; };
};
"yanlin@vps" = home-manager.lib.homeManagerConfiguration {
@ -105,11 +92,6 @@
extraSpecialArgs = { inherit nixvim; };
};
"yanlin@deck" = home-manager.lib.homeManagerConfiguration {
pkgs = nixpkgs.legacyPackages.x86_64-linux;
modules = [ ./hosts/nixos/deck/home.nix ];
extraSpecialArgs = { inherit nixvim; };
};
};
};
}

View file

@ -1,4 +1,4 @@
{ config, pkgs, nixvim, claude-code, firefox-addons, ... }:
{ config, pkgs, nixvim, firefox-addons, ... }:
{
imports = [
@ -168,16 +168,7 @@
delta
fastfetch
coreutils # GNU core utilities (base64, etc.)
tree
bzip2
duti # Set default applications for file types (macOS)
pdftk
# Development and build tools
python312
uv
lazysql
sqlite
];
# Startup applications via launchd agents

View file

@ -49,12 +49,5 @@
ncdu
delta
fastfetch
bzip2
# Development and build tools
python312
uv
lazysql
sqlite
];
}

View file

@ -1,18 +1,8 @@
{ config, pkgs, lib, claude-code, ... }:
{ config, pkgs, lib, ... }:
with lib;
let
# Detect system architecture and select appropriate package
claudePackage = if pkgs.stdenv.hostPlatform.system == "aarch64-darwin" then
claude-code.packages.aarch64-darwin.claude-code
else if pkgs.stdenv.hostPlatform.system == "x86_64-linux" then
claude-code.packages.x86_64-linux.claude-code
else if pkgs.stdenv.hostPlatform.system == "aarch64-linux" then
claude-code.packages.aarch64-linux.claude-code
else
throw "Unsupported system for Claude Code: ${pkgs.stdenv.hostPlatform.system}";
# Default global permissions
defaultPermissions = {
allow = [
@ -152,7 +142,7 @@ in
config = {
# Install Claude Code package
home.packages = [
claudePackage
pkgs.claude-code
pkgs.poppler-utils
];