Skip to content
Snippets Groups Projects
Commit 19b5cb46 authored by Evy Storozhenko's avatar Evy Storozhenko
Browse files

initial day02

parent 61c48b91
No related branches found
No related tags found
No related merge requests found
use flake
# rust
target/
# This file is automatically @generated by Cargo.
# It is not intended for manual editing.
version = 3
[[package]]
name = "day02"
version = "0.1.0"
[package]
name = "day02"
version = "0.1.0"
edition = "2021"
# See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html
[dependencies]
{
description = "AoC 2023 - day 02";
inputs = {
nixpkgs.url = "github:NixOS/nixpkgs/nixos-23.05";
naersk = {
url = "github:nix-community/naersk/master";
inputs.nixpkgs.follows = "nixpkgs";
};
utils.url = "github:numtide/flake-utils";
};
outputs = { self, nixpkgs, utils, naersk }:
utils.lib.eachDefaultSystem (system:
let
pkgs = import nixpkgs { inherit system; };
naerskBuildPackage = (conf:
(pkgs.callPackage naersk { }).buildPackage ({ src = ./.; } // conf)
);
in
{
defaultPackage = naerskBuildPackage { };
devShell = with pkgs; mkShell {
buildInputs = [ cargo rustc rustfmt ];
};
});
}
fn main() {
println!("Hello, world!");
}
......@@ -10,12 +10,12 @@
},
"locked": {
"lastModified": 1,
"narHash": "sha256-tY3L0BwQAOShopkV4HZ+v9zwM16Yj+joLr+5xi6Bwx8=",
"path": "/nix/store/wl49h89zff154wpqbagplgk7sw1z74ds-source/day01",
"narHash": "sha256-Ks2BdODzP+gqgz4u9o4boZIqE0KnzrpA7FqLQ4IuBdc=",
"path": "/nix/store/zprw6qgx4v1m92zfzirmmli192k6cgrf-source/day01",
"type": "path"
},
"original": {
"path": "/nix/store/wl49h89zff154wpqbagplgk7sw1z74ds-source/day01",
"path": "/nix/store/zprw6qgx4v1m92zfzirmmli192k6cgrf-source/day01",
"type": "path"
}
},
......@@ -28,12 +28,31 @@
},
"locked": {
"lastModified": 1,
"narHash": "sha256-gwH89EDWFx3eparAlrWPU/9GnsltYgNk0Kia2ZwycgI=",
"path": "/nix/store/wl49h89zff154wpqbagplgk7sw1z74ds-source/day01cpp",
"narHash": "sha256-8Yu/GKz1zA91/CL5PgmiBRxE2h+bb9uRLHK1HTtmLbQ=",
"path": "/nix/store/zprw6qgx4v1m92zfzirmmli192k6cgrf-source/day01cpp",
"type": "path"
},
"original": {
"path": "/nix/store/wl49h89zff154wpqbagplgk7sw1z74ds-source/day01cpp",
"path": "/nix/store/zprw6qgx4v1m92zfzirmmli192k6cgrf-source/day01cpp",
"type": "path"
}
},
"day02": {
"inputs": {
"naersk": "naersk_2",
"nixpkgs": [
"nixpkgs"
],
"utils": "utils_3"
},
"locked": {
"lastModified": 1,
"narHash": "sha256-sHAKZV5MGsQlBCKKgaKaKtXHP9aSTOadM94p1yMM4Aw=",
"path": "/nix/store/zprw6qgx4v1m92zfzirmmli192k6cgrf-source/day02",
"type": "path"
},
"original": {
"path": "/nix/store/zprw6qgx4v1m92zfzirmmli192k6cgrf-source/day02",
"type": "path"
}
},
......@@ -60,6 +79,28 @@
}
},
"naersk_2": {
"inputs": {
"nixpkgs": [
"day02",
"nixpkgs"
]
},
"locked": {
"lastModified": 1698420672,
"narHash": "sha256-/TdeHMPRjjdJub7p7+w55vyABrsJlt5QkznPYy55vKA=",
"owner": "nix-community",
"repo": "naersk",
"rev": "aeb58d5e8faead8980a807c840232697982d47b9",
"type": "github"
},
"original": {
"owner": "nix-community",
"ref": "master",
"repo": "naersk",
"type": "github"
}
},
"naersk_3": {
"inputs": {
"nixpkgs": [
"nixpkgs"
......@@ -100,9 +141,10 @@
"inputs": {
"day01": "day01",
"day01cpp": "day01cpp",
"naersk": "naersk_2",
"day02": "day02",
"naersk": "naersk_3",
"nixpkgs": "nixpkgs",
"utils": "utils_3"
"utils": "utils_4"
}
},
"systems": {
......@@ -150,6 +192,21 @@
"type": "github"
}
},
"systems_4": {
"locked": {
"lastModified": 1681028828,
"narHash": "sha256-Vy1rq5AaRuLzOxct8nz4T6wlgyUR7zLU309k9mBC768=",
"owner": "nix-systems",
"repo": "default",
"rev": "da67096a3b9bf56a91d16901293e51ba5b49a27e",
"type": "github"
},
"original": {
"owner": "nix-systems",
"repo": "default",
"type": "github"
}
},
"utils": {
"inputs": {
"systems": "systems"
......@@ -203,6 +260,24 @@
"repo": "flake-utils",
"type": "github"
}
},
"utils_4": {
"inputs": {
"systems": "systems_4"
},
"locked": {
"lastModified": 1694529238,
"narHash": "sha256-zsNZZGTGnMOf9YpHKJqMSsa0dXbfmxeoJ7xHlrt+xmY=",
"owner": "numtide",
"repo": "flake-utils",
"rev": "ff7b65b44d01cf9ba6a71320833626af21126384",
"type": "github"
},
"original": {
"owner": "numtide",
"repo": "flake-utils",
"type": "github"
}
}
},
"root": "root",
......
......@@ -11,6 +11,10 @@
url = "./day01cpp";
inputs.nixpkgs.follows = "nixpkgs";
};
day02 = {
url = "./day02";
inputs.nixpkgs.follows = "nixpkgs";
};
naersk = {
url = "github:nix-community/naersk/master";
inputs.nixpkgs.follows = "nixpkgs";
......@@ -18,7 +22,7 @@
utils.url = "github:numtide/flake-utils";
};
outputs = { self, nixpkgs, utils, naersk, day01, day01cpp }:
outputs = { self, nixpkgs, utils, naersk, day01, day01cpp, day02 }:
utils.lib.eachDefaultSystem (system:
let
pkgs = import nixpkgs { inherit system; };
......@@ -27,6 +31,7 @@
packages = {
day01 = day01.defaultPackage.${system};
day01cpp = day01cpp.defaultPackage.${system};
day02 = day01.defaultPackage.${system};
};
}
);
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment