lohr/flake.nix

53 lines
1.3 KiB
Nix
Raw Normal View History

2021-03-29 20:00:01 +02:00
{
inputs = {
nixpkgs.url = "github:NixOS/nixpkgs/nixpkgs-unstable";
flake-utils.url = "github:numtide/flake-utils";
flake-compat = {
url = "github:edolstra/flake-compat";
flake = false;
};
2021-03-29 20:00:01 +02:00
};
outputs = { self, nixpkgs, flake-utils, ... }:
2021-03-29 20:00:01 +02:00
flake-utils.lib.eachDefaultSystem (system:
let
pkgs = import nixpkgs { inherit system; };
in
{
defaultPackage = pkgs.rustPlatform.buildRustPackage {
2021-03-29 22:47:42 +02:00
pname = "lohr";
2023-12-12 15:46:33 +01:00
version = "0.4.5";
src = ./.;
2023-12-12 15:46:33 +01:00
cargoHash = "sha256-hext0S0o9D9pN9epzXtD5dwAYMPCLpBBOBT4FX0mTMk=";
meta = with pkgs.lib; {
description = "A Git mirroring tool";
homepage = "https://github.com/alarsyo/lohr";
license = with licenses; [ mit asl20 ];
platforms = platforms.unix;
};
2021-03-29 22:47:42 +02:00
};
2021-03-29 20:00:01 +02:00
defaultApp = flake-utils.lib.mkApp {
drv = self.defaultPackage."${system}";
};
devShell = pkgs.mkShell {
buildInputs = with pkgs; [
cargo
clippy
2021-03-29 20:00:01 +02:00
nixpkgs-fmt
pre-commit
rustPackages.clippy
rustc
2021-03-29 20:00:01 +02:00
rustfmt
2023-12-12 14:57:37 +01:00
rust-analyzer
2021-03-29 20:00:01 +02:00
];
RUST_SRC_PATH = pkgs.rustPlatform.rustLibSrc;
};
});
}