aoc/2024/01/flake.nix

32 lines
773 B
Nix
Raw Normal View History

2024-12-01 11:02:04 +00:00
{
description = "A very basic flake";
inputs = {
nixpkgs.url = "github:nixos/nixpkgs?ref=nixos-unstable";
tix.url = "git+https://git.tristans.cloud/tristan/tix";
};
outputs = { self, nixpkgs, tix }: let
pkgs = import nixpkgs {system = "x86_64-linux";};
p1 = import ./part1.nix pkgs;
in {
part1example = (p1 {file = ./example.txt;}).result;
part1 = (p1 {file = ./input.txt;}).result;
part2example = (p1 {file = ./example.txt;}).part2result;
part2 = (p1 {file = ./input.txt;}).part2result;
packages.x86_64-linux.watch = tix.watch {
cmd = ''
nix run .\#test --impure --extra-experimental-features pipe-operators
'';
};
packages.x86_64-linux.test = tix.run [
./part1.test.nix
];
};
}