2024-09-13 12:22:00 +00:00
|
|
|
{
|
|
|
|
lib,
|
|
|
|
rustPlatform,
|
|
|
|
fetchFromGitHub,
|
|
|
|
pkg-config,
|
|
|
|
libgit2,
|
|
|
|
rust-jemalloc-sys,
|
|
|
|
zlib,
|
|
|
|
git,
|
2023-09-01 02:25:59 +00:00
|
|
|
}:
|
|
|
|
rustPlatform.buildRustPackage rec {
|
|
|
|
pname = "biome";
|
2024-10-25 10:14:11 +00:00
|
|
|
version = "1.9.4";
|
2023-09-01 02:25:59 +00:00
|
|
|
|
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "biomejs";
|
|
|
|
repo = "biome";
|
|
|
|
rev = "cli/v${version}";
|
2024-10-25 10:14:11 +00:00
|
|
|
hash = "sha256-oK1tCPoTeUHvVdi+ym4J5xEj2NIi2zHQpNU1KUchQfY=";
|
2023-09-01 02:25:59 +00:00
|
|
|
};
|
|
|
|
|
2024-10-25 10:14:11 +00:00
|
|
|
cargoHash = "sha256-4vITbsXfgNFoeWMHz7a9Rk7FrsEZRe75nHiyHSMujEQ=";
|
2023-09-01 02:25:59 +00:00
|
|
|
|
2024-11-06 22:15:22 +00:00
|
|
|
nativeBuildInputs = [ pkg-config ];
|
2023-09-01 02:25:59 +00:00
|
|
|
|
2024-11-06 22:15:22 +00:00
|
|
|
buildInputs = [
|
|
|
|
libgit2
|
|
|
|
rust-jemalloc-sys
|
|
|
|
zlib
|
2023-09-01 02:25:59 +00:00
|
|
|
];
|
|
|
|
|
2024-11-06 22:15:22 +00:00
|
|
|
nativeCheckInputs = [ git ];
|
|
|
|
|
2023-09-15 14:55:59 +00:00
|
|
|
cargoBuildFlags = [ "-p=biome_cli" ];
|
2024-09-13 12:22:00 +00:00
|
|
|
cargoTestFlags =
|
|
|
|
cargoBuildFlags
|
|
|
|
++
|
2024-05-09 10:26:11 +00:00
|
|
|
# skip a broken test from v1.7.3 release
|
2024-02-21 15:22:08 +00:00
|
|
|
# this will be removed on the next version
|
|
|
|
[ "-- --skip=diagnostics::test::termination_diagnostic_size" ];
|
2023-09-01 02:25:59 +00:00
|
|
|
|
|
|
|
env = {
|
|
|
|
BIOME_VERSION = version;
|
2024-02-11 21:37:33 +00:00
|
|
|
LIBGIT2_NO_VENDOR = 1;
|
2023-09-01 02:25:59 +00:00
|
|
|
};
|
|
|
|
|
|
|
|
preCheck = ''
|
|
|
|
# tests assume git repository
|
|
|
|
git init
|
|
|
|
|
|
|
|
# tests assume $BIOME_VERSION is unset
|
|
|
|
unset BIOME_VERSION
|
|
|
|
'';
|
|
|
|
|
2024-09-13 12:22:00 +00:00
|
|
|
meta = {
|
2023-09-01 02:25:59 +00:00
|
|
|
description = "Toolchain of the web";
|
|
|
|
homepage = "https://biomejs.dev/";
|
|
|
|
changelog = "https://github.com/biomejs/biome/blob/${src.rev}/CHANGELOG.md";
|
2024-09-13 12:22:00 +00:00
|
|
|
license = lib.licenses.mit;
|
|
|
|
maintainers = with lib.maintainers; [
|
|
|
|
figsoda
|
|
|
|
isabelroses
|
|
|
|
];
|
2023-09-01 02:25:59 +00:00
|
|
|
mainProgram = "biome";
|
|
|
|
};
|
|
|
|
}
|