feat: 新增 laptop 主机配置(Ultra 9 285H / Arc)

- hosts/laptop/hardware.nix: 本机真实硬件配置(btrfs 子卷 / NPU / 微码)
- hosts/laptop/default.nix: 复用 common/desktop-plasma/chinese/gaming/printing/apps,跳过 nvidia 与 fpga;加 Intel Arc VA-API
- flake.nix: 抽出 mkSystem,新增 nixosConfigurations.laptop / nixos
This commit is contained in:
WHC
2026-09-21 23:45:25 +08:00
parent b0ee60f7a2
commit cf6e2a1a48
3 changed files with 82 additions and 4 deletions
+10 -4
View File
@@ -1,5 +1,5 @@
{
description = "whc NixOS — desktop (i7-12700F + RTX 4060)";
description = "whc NixOS — desktop (i7-12700F + RTX 4060) + laptop (Ultra 9 285H / Arc)";
inputs = {
nixpkgs.url = "github:NixOS/nixpkgs/nixos-unstable";
@@ -9,11 +9,17 @@
{ self, nixpkgs, ... }:
let
system = "x86_64-linux";
mkSystem = host: nixpkgs.lib.nixosSystem {
inherit system;
modules = [ (./hosts + "/${host}") ];
};
in
{
nixosConfigurations.desktop = nixpkgs.lib.nixosSystem {
inherit system;
modules = [ ./hosts/desktop ];
nixosConfigurations = {
desktop = mkSystem "desktop";
laptop = mkSystem "laptop";
# hostname 仍是 nixos:让不带 attr 的 `nixos-rebuild --flake .#` 也能命中
nixos = mkSystem "laptop";
};
# 无 flake 时也可:把本仓库拷到 /etc/nixos 后 nixos-rebuild switch