2022-09-11 15:47:08 +00:00
|
|
|
{ lib
|
2022-12-17 10:02:37 +00:00
|
|
|
, stdenv
|
2022-09-11 15:47:08 +00:00
|
|
|
, rustPlatform
|
|
|
|
, fetchFromGitHub
|
|
|
|
}:
|
|
|
|
|
|
|
|
rustPlatform.buildRustPackage rec {
|
|
|
|
pname = "lightningcss";
|
2023-01-20 10:41:00 +00:00
|
|
|
version = "1.18.0";
|
2022-09-11 15:47:08 +00:00
|
|
|
|
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "parcel-bundler";
|
|
|
|
repo = "lightningcss";
|
2022-12-17 10:02:37 +00:00
|
|
|
rev = "refs/tags/v${version}";
|
2023-01-20 10:41:00 +00:00
|
|
|
sha256 = "sha256-JULVX5gyMJhnBwGQxmMObtUaenu37rIE5yDbA5fHsCY=";
|
2022-09-11 15:47:08 +00:00
|
|
|
};
|
|
|
|
|
2023-01-20 10:41:00 +00:00
|
|
|
cargoHash = "sha256-PQbN0qsCf4eia5sD71ltP7Y955smZPwkof+uEQATvNQ=";
|
2022-09-11 15:47:08 +00:00
|
|
|
|
2022-12-17 10:02:37 +00:00
|
|
|
buildFeatures = [
|
|
|
|
"cli"
|
|
|
|
];
|
2022-09-11 15:47:08 +00:00
|
|
|
|
2022-12-17 10:02:37 +00:00
|
|
|
cargoBuildFlags = [
|
|
|
|
"--lib"
|
|
|
|
"--bin=lightningcss"
|
|
|
|
];
|
2022-09-11 15:47:08 +00:00
|
|
|
|
2022-12-17 10:02:37 +00:00
|
|
|
cargoTestFlags = [
|
|
|
|
"--lib"
|
|
|
|
];
|
2022-09-11 15:47:08 +00:00
|
|
|
|
|
|
|
meta = with lib; {
|
|
|
|
description = "Extremely fast CSS parser, transformer, and minifier written in Rust";
|
|
|
|
homepage = "https://lightningcss.dev/";
|
2022-12-17 10:02:37 +00:00
|
|
|
changelog = "https://github.com/parcel-bundler/lightningcss/releases/tag/v${version}";
|
2022-09-11 15:47:08 +00:00
|
|
|
license = licenses.mpl20;
|
|
|
|
maintainers = with maintainers; [ toastal ];
|
2022-12-17 10:02:37 +00:00
|
|
|
# never built on aarch64-linux since first introduction in nixpkgs
|
|
|
|
broken = stdenv.isLinux && stdenv.isAarch64;
|
2022-09-11 15:47:08 +00:00
|
|
|
};
|
|
|
|
}
|