Compare commits

..

7 Commits

5 changed files with 380 additions and 675 deletions
+4 -13
View File
@@ -1,13 +1,4 @@
.luarc.json /.direnv
target /.luarc.json
/result*
# Devenv /target
.devenv*
devenv.local.nix
devenv.local.yaml
# direnv
.direnv
# pre-commit
.pre-commit-config.yaml
Generated
+303 -611
View File
File diff suppressed because it is too large Load Diff
+5 -9
View File
@@ -1,19 +1,15 @@
{ {
lib, craneLib,
pkgs, pkgs,
rust,
self,
}: }:
pkgs.rustPlatform.buildRustPackage { craneLib.buildPackage {
pname = "errornowatcher"; pname = "errornowatcher";
version = self.shortRev or self.dirtyShortRev; version = "0.2.0";
cargoLock.lockFile = ./Cargo.lock; src = craneLib.cleanCargoSource ./.;
src = lib.cleanSource ./.;
nativeBuildInputs = with pkgs; [ nativeBuildInputs = with pkgs; [
rust clang
mold mold
pkg-config pkg-config
]; ];
Generated
+55 -21
View File
@@ -1,15 +1,51 @@
{ {
"nodes": { "nodes": {
"crane": {
"locked": {
"lastModified": 1778106249,
"narHash": "sha256-cM/AuKy5tMhwOOQIbha8ZRRMHVfNf7cv2aljIw+qoCg=",
"owner": "ipetkov",
"repo": "crane",
"rev": "6d015ea29630b7ad2402841386da2cb617a470a7",
"type": "github"
},
"original": {
"owner": "ipetkov",
"repo": "crane",
"type": "github"
}
},
"fenix": {
"inputs": {
"nixpkgs": [
"nixpkgs"
],
"rust-analyzer-src": "rust-analyzer-src"
},
"locked": {
"lastModified": 1778314245,
"narHash": "sha256-a8p3JMunVzj0o86V9CNTyEFw7z4105QWl+bEz6Du8Jw=",
"owner": "nix-community",
"repo": "fenix",
"rev": "f54d645218048a7abe226983a922cdaca63cd845",
"type": "github"
},
"original": {
"owner": "nix-community",
"repo": "fenix",
"type": "github"
}
},
"flake-parts": { "flake-parts": {
"inputs": { "inputs": {
"nixpkgs-lib": "nixpkgs-lib" "nixpkgs-lib": "nixpkgs-lib"
}, },
"locked": { "locked": {
"lastModified": 1777678872, "lastModified": 1777988971,
"narHash": "sha256-EPIFsulyon7Z1vLQq5Fk64GR8L7cQsT+IPhcsukVbgk=", "narHash": "sha256-qIoWPDs+0/8JecyYgE3gpKQxW/4bLW/gp45vow9ioCQ=",
"owner": "hercules-ci", "owner": "hercules-ci",
"repo": "flake-parts", "repo": "flake-parts",
"rev": "5250617bffd85403b14dbf43c3870e7f255d2c16", "rev": "0678d8986be1661af6bb555f3489f2fdfc31f6ff",
"type": "github" "type": "github"
}, },
"original": { "original": {
@@ -20,11 +56,11 @@
}, },
"nixpkgs": { "nixpkgs": {
"locked": { "locked": {
"lastModified": 1777268161, "lastModified": 1777954456,
"narHash": "sha256-bxrdOn8SCOv8tN4JbTF/TXq7kjo9ag4M+C8yzzIRYbE=", "narHash": "sha256-hGdgeU2Nk87RAuZyYjyDjFL6LK7dAZN5RE9+hrDTkDU=",
"owner": "NixOS", "owner": "NixOS",
"repo": "nixpkgs", "repo": "nixpkgs",
"rev": "1c3fe55ad329cbcb28471bb30f05c9827f724c76", "rev": "549bd84d6279f9852cae6225e372cc67fb91a4c1",
"type": "github" "type": "github"
}, },
"original": { "original": {
@@ -51,28 +87,26 @@
}, },
"root": { "root": {
"inputs": { "inputs": {
"crane": "crane",
"fenix": "fenix",
"flake-parts": "flake-parts", "flake-parts": "flake-parts",
"nixpkgs": "nixpkgs", "nixpkgs": "nixpkgs"
"rust-overlay": "rust-overlay"
} }
}, },
"rust-overlay": { "rust-analyzer-src": {
"inputs": { "flake": false,
"nixpkgs": [
"nixpkgs"
]
},
"locked": { "locked": {
"lastModified": 1777605393, "lastModified": 1778246258,
"narHash": "sha256-Hjp0VOOHgHcTrX23iVvnfAudPcuCmfkfpQNFwv2v/ks=", "narHash": "sha256-RUZuOfzouSaK/VjcOCU/P5Nb3EhpM8qGnIcHWIIo4Sw=",
"owner": "oxalica", "owner": "rust-lang",
"repo": "rust-overlay", "repo": "rust-analyzer",
"rev": "ff88db34cfa486fc4964a6991cab1678d82eee8c", "rev": "73ca1d4ef136e2367627d698f00db94882b49440",
"type": "github" "type": "github"
}, },
"original": { "original": {
"owner": "oxalica", "owner": "rust-lang",
"repo": "rust-overlay", "ref": "nightly",
"repo": "rust-analyzer",
"type": "github" "type": "github"
} }
} }
+13 -21
View File
@@ -1,21 +1,22 @@
{ {
inputs = { inputs = {
crane.url = "github:ipetkov/crane";
fenix = {
url = "github:nix-community/fenix";
inputs.nixpkgs.follows = "nixpkgs";
};
flake-parts.url = "github:hercules-ci/flake-parts"; flake-parts.url = "github:hercules-ci/flake-parts";
nixpkgs.url = "github:NixOS/nixpkgs/nixos-unstable"; nixpkgs.url = "github:NixOS/nixpkgs/nixos-unstable";
rust-overlay = {
url = "github:oxalica/rust-overlay";
inputs.nixpkgs.follows = "nixpkgs";
};
}; };
outputs = outputs =
{ {
crane,
fenix,
flake-parts, flake-parts,
nixpkgs,
rust-overlay,
self,
... ...
}@inputs: }@inputs:
flake-parts.lib.mkFlake { inherit inputs; } { flake-parts.lib.mkFlake { inherit inputs; } {
@@ -32,32 +33,23 @@
... ...
}: }:
let let
rust = pkgs.rust-bin.nightly.latest.default.override { craneLib = (crane.mkLib pkgs).overrideToolchain fenix.packages.${system}.complete.toolchain;
extensions = [
"rust-src"
"rust-analyzer-preview"
];
};
in in
{ {
_module.args.pkgs = import nixpkgs { devShells.default = craneLib.devShell {
inherit system;
overlays = [ rust-overlay.overlays.default ];
};
devShells.default = pkgs.mkShell {
name = "errornowatcher"; name = "errornowatcher";
inputsFrom = [ self'.packages.default ]; inputsFrom = [ self'.packages.default ];
nativeBuildInputs = [ pkgs.pkg-config ]; nativeBuildInputs = [ pkgs.pkg-config ];
buildInputs = [ pkgs.taplo ]; buildInputs = [ pkgs.taplo ];
PKG_CONFIG_PATH = "${pkgs.openssl.dev}/lib/pkgconfig";
RUST_BACKTRACE = 1; RUST_BACKTRACE = 1;
}; };
packages = rec { packages = rec {
default = errornowatcher; default = errornowatcher;
errornowatcher = pkgs.callPackage ./. { inherit rust self; }; errornowatcher = pkgs.callPackage ./. { inherit craneLib; };
}; };
}; };
}; };