lol
at 23.11-beta 65 lines 1.2 kB view raw
1{ lib 2, rustPlatform 3, fetchFromGitHub 4, pkg-config 5, libgit2_1_6 6, rust-jemalloc-sys 7, zlib 8, stdenv 9, darwin 10, git 11}: 12 13rustPlatform.buildRustPackage rec { 14 pname = "biome"; 15 version = "1.3.3"; 16 17 src = fetchFromGitHub { 18 owner = "biomejs"; 19 repo = "biome"; 20 rev = "cli/v${version}"; 21 hash = "sha256-1yVXzPbLqLiqn3RN3mZNULOabydYtjXam+BB3aKwhTs="; 22 }; 23 24 cargoHash = "sha256-3EkYxq80fkRJ1U4nLtp7dYEEFaqDhgptnNsNghFQAZI="; 25 26 nativeBuildInputs = [ 27 pkg-config 28 ]; 29 30 buildInputs = [ 31 libgit2_1_6 32 rust-jemalloc-sys 33 zlib 34 ] ++ lib.optionals stdenv.isDarwin [ 35 darwin.apple_sdk.frameworks.Security 36 ]; 37 38 nativeCheckInputs = [ 39 git 40 ]; 41 42 cargoBuildFlags = [ "-p=biome_cli" ]; 43 cargoTestFlags = cargoBuildFlags; 44 45 env = { 46 BIOME_VERSION = version; 47 }; 48 49 preCheck = '' 50 # tests assume git repository 51 git init 52 53 # tests assume $BIOME_VERSION is unset 54 unset BIOME_VERSION 55 ''; 56 57 meta = with lib; { 58 description = "Toolchain of the web"; 59 homepage = "https://biomejs.dev/"; 60 changelog = "https://github.com/biomejs/biome/blob/${src.rev}/CHANGELOG.md"; 61 license = licenses.mit; 62 maintainers = with maintainers; [ figsoda ]; 63 mainProgram = "biome"; 64 }; 65}