1{
2 lib,
3 stdenv,
4 rustPlatform,
5 fetchFromGitHub,
6 libiconv,
7}:
8
9rustPlatform.buildRustPackage rec {
10 pname = "code-minimap";
11 version = "0.6.8";
12
13 src = fetchFromGitHub {
14 owner = "wfxr";
15 repo = "code-minimap";
16 rev = "v${version}";
17 sha256 = "sha256-unf7gFc/tQiUw3VqQ0KC96Srxn1E27WsmJviSggaCF4=";
18 };
19
20 cargoHash = "sha256-35qMpxROBnXfnTIAkCRUg7zRQTvSIIA2qGD0Vu9r488=";
21
22 buildInputs = lib.optional stdenv.hostPlatform.isDarwin libiconv;
23
24 meta = with lib; {
25 description = "High performance code minimap render";
26 homepage = "https://github.com/wfxr/code-minimap";
27 license = with licenses; [
28 asl20 # or
29 mit
30 ];
31 maintainers = with maintainers; [ bsima ];
32 mainProgram = "code-minimap";
33 };
34}