Kieran's opinionated (and probably slightly dumb) nix config

feat: add arduino tools

+44
+17
flake.lock
··· 482 482 "type": "github" 483 483 } 484 484 }, 485 + "nixpkgs-unstable": { 486 + "locked": { 487 + "lastModified": 1722185531, 488 + "narHash": "sha256-veKR07psFoJjINLC8RK4DiLniGGMgF3QMlS4tb74S6k=", 489 + "owner": "nixos", 490 + "repo": "nixpkgs", 491 + "rev": "52ec9ac3b12395ad677e8b62106f0b98c1f8569d", 492 + "type": "github" 493 + }, 494 + "original": { 495 + "owner": "nixos", 496 + "ref": "nixos-unstable", 497 + "repo": "nixpkgs", 498 + "type": "github" 499 + } 500 + }, 485 501 "nixpkgs_2": { 486 502 "locked": { 487 503 "lastModified": 1697723726, ··· 574 590 "nix-vscode-extensions": "nix-vscode-extensions", 575 591 "nixos-hardware": "nixos-hardware", 576 592 "nixpkgs": "nixpkgs_6", 593 + "nixpkgs-unstable": "nixpkgs-unstable", 577 594 "spicetify-nix": "spicetify-nix" 578 595 } 579 596 },
+16
flake.nix
··· 4 4 inputs = { 5 5 # Nixpkgs 6 6 nixpkgs.url = "github:nixos/nixpkgs/nixos-24.05"; 7 + nixpkgs-unstable.url = "github:nixos/nixpkgs/nixos-unstable"; 7 8 8 9 # NixOS hardware configuration 9 10 hardware.url = "github:NixOS/nixos-hardware/master"; ··· 38 39 outputs = { 39 40 self, 40 41 nixpkgs, 42 + nixpkgs-unstable, 41 43 agenix, 42 44 home-manager, 43 45 nixos-hardware, ··· 45 47 ... 46 48 } @ inputs: let 47 49 inherit (self) outputs; 50 + system = "x86_64-linux"; 51 + unstable-overlays = { 52 + nixpkgs.overlays = [ 53 + (final: prev: { 54 + unstable = import nixpkgs-unstable { 55 + inherit system; 56 + config.allowUnfree = true; 57 + }; 58 + }) 59 + ]; 60 + }; 48 61 in { 49 62 # NixOS configuration entrypoint 50 63 # Available through 'nixos-rebuild --flake .#your-hostname' 51 64 nixosConfigurations = { 52 65 moonlark = nixpkgs.lib.nixosSystem { 53 66 system = "x86_64-linux"; 67 + 54 68 specialArgs = {inherit inputs outputs;}; 69 + 55 70 # > Our main nixos configuration file < 56 71 modules = [ 57 72 inputs.disko.nixosModules.disko 58 73 { disko.devices.disk.disk1.device = "/dev/vda"; } 59 74 agenix.nixosModules.default 60 75 ./moonlark/configuration.nix 76 + unstable-overlays 61 77 ]; 62 78 }; 63 79 };
+7
home-manager/home.nix
··· 382 382 github.vscode-github-actions 383 383 yoavbls.pretty-ts-errors 384 384 esbenp.prettier-vscode 385 + vsciot-vscode.vscode-arduino 386 + ms-vscode.cpptools 387 + ms-vscode.vscode-serial-monitor 385 388 ]; 386 389 userSettings = { 387 390 "editor.semanticHighlighting.enabled" = true; ··· 398 401 "git.autofetch" = true; 399 402 "git.confirmSync" = false; 400 403 "github.copilot.editor.enableAutoCompletions" = false; 404 + 405 + "[json]" = { 406 + "editor.defaultFormatter" = "esbenp.prettier-vscode"; 407 + }; 401 408 }; 402 409 }; 403 410
+4
moonlark/configuration.nix
··· 6 6 lib, 7 7 config, 8 8 pkgs, 9 + pkgs-unstable, 9 10 ... 10 11 }: { 11 12 # You can import other NixOS modules here ··· 75 76 pkgs.alacritty 76 77 pkgs.zsh 77 78 pkgs.starship 79 + pkgs.gh 78 80 pkgs.swww 79 81 pkgs.sunwait 80 82 pkgs.sunpaper ··· 105 107 pkgs.go 106 108 pkgs.bun 107 109 pkgs.pitivi 110 + pkgs.unstable.arduino-ide 111 + pkgs.unstable.arduino-cli 108 112 ]; 109 113 110 114 services.gnome.gnome-keyring.enable = true;