2023-12-23 16:41:39 +00:00
|
|
|
{ lib
|
2024-06-21 13:53:32 +00:00
|
|
|
, stdenv
|
2023-12-23 16:41:39 +00:00
|
|
|
, rustPlatform
|
|
|
|
, fetchFromGitHub
|
|
|
|
, pkg-config
|
|
|
|
, openssl
|
|
|
|
, git
|
|
|
|
, gitls
|
2024-06-21 13:53:32 +00:00
|
|
|
, darwin
|
2023-12-23 16:41:39 +00:00
|
|
|
}:
|
|
|
|
rustPlatform.buildRustPackage rec {
|
|
|
|
pname = "licensure";
|
2024-08-23 09:56:13 +00:00
|
|
|
version = "0.5.1";
|
2023-12-23 16:41:39 +00:00
|
|
|
|
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "chasinglogic";
|
|
|
|
repo = "licensure";
|
|
|
|
rev = version;
|
2024-08-23 09:56:13 +00:00
|
|
|
hash = "sha256-bo1bac/K8HMZaeLVYZRqYOS8p+62suGlgSyYz8Atj+0=";
|
2023-12-23 16:41:39 +00:00
|
|
|
};
|
|
|
|
|
2024-08-23 09:56:13 +00:00
|
|
|
cargoHash = "sha256-Ywfn+6qdKD9CG2/xdHR2XDsj5LF5XPJ2+XR5H1o2iXk=";
|
2023-12-23 16:41:39 +00:00
|
|
|
nativeBuildInputs = [ pkg-config ];
|
2024-06-21 13:53:32 +00:00
|
|
|
buildInputs = [ openssl git gitls ]
|
|
|
|
++ lib.optionals stdenv.isDarwin [
|
|
|
|
darwin.apple_sdk.frameworks.SystemConfiguration
|
|
|
|
];
|
2023-12-23 16:41:39 +00:00
|
|
|
|
|
|
|
checkFlags = [
|
|
|
|
# Checking for files in the git repo (git ls-files),
|
|
|
|
# That obviously does not work with nix
|
|
|
|
"--skip=test_get_project_files"
|
|
|
|
];
|
|
|
|
|
|
|
|
meta = with lib; {
|
|
|
|
description = "FOSS License management tool for your projects";
|
|
|
|
homepage = "https://github.com/chasinglogic/licensure";
|
|
|
|
license = licenses.gpl3Plus;
|
|
|
|
mainProgram = "licensure";
|
|
|
|
maintainers = [ maintainers.soispha ];
|
2024-06-21 13:53:32 +00:00
|
|
|
platforms = platforms.linux ++ platforms.darwin;
|
2023-12-23 16:41:39 +00:00
|
|
|
};
|
|
|
|
}
|