Nix packages for third-party projects that don't ship their own flakes
0

Configure Feed

Select the types of activity you want to include in your feed.

agentic / flake.nix
1.2 kB 49 lines
1{ 2 description = "Nix packages for third-party projects that don't ship their own flakes"; 3 4 inputs = { 5 nixpkgs.url = "github:NixOS/nixpkgs/nixos-unstable"; 6 }; 7 8 outputs = 9 { self, nixpkgs }: 10 let 11 systems = [ 12 "x86_64-linux" 13 "aarch64-linux" 14 "x86_64-darwin" 15 "aarch64-darwin" 16 ]; 17 forAllSystems = nixpkgs.lib.genAttrs systems; 18 in 19 { 20 packages = forAllSystems ( 21 system: 22 let 23 pkgs = nixpkgs.legacyPackages.${system}; 24 in 25 { 26 vit = pkgs.callPackage ./packages/vit { }; 27 spinel = pkgs.callPackage ./packages/spinel { }; 28 default = self.packages.${system}.vit; 29 } 30 ); 31 32 # Convenience: `nix run .#vit -- --help`, `nix run .#spinel -- --help` 33 apps = forAllSystems (system: { 34 vit = { 35 type = "app"; 36 program = "${self.packages.${system}.vit}/bin/vit"; 37 }; 38 spinel = { 39 type = "app"; 40 program = "${self.packages.${system}.spinel}/bin/spinel"; 41 }; 42 spin = { 43 type = "app"; 44 program = "${self.packages.${system}.spinel}/bin/spin"; 45 }; 46 default = self.apps.${system}.vit; 47 }); 48 }; 49}