about summary refs log tree commit diff
path: root/pkgs/by-name/de/dep-tree/package.nix
blob: 27745d340e21c0bd9897421339db83d22d8408d2 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
{
  lib,
  fetchFromGitHub,
  buildGoModule,
  linkFarm,
}:
let
  testDeps = {
    react-stl-viewer = fetchFromGitHub {
      owner = "gabotechs";
      repo = "react-stl-viewer";
      rev = "2.2.4";
      sha256 = "sha256-0u9q0UgOn43PE1Y6BUhl1l6RnVjpPraFqZWB+HhQ0s8=";
    };
    react-gcode-viewer = fetchFromGitHub {
      owner = "gabotechs";
      repo = "react-gcode-viewer";
      rev = "2.2.4";
      sha256 = "sha256-FHBICLdy0k4j3pPKStg+nkIktMpKS1ADa4m1vYHJ+AQ=";
    };
    graphql-js = fetchFromGitHub {
      owner = "graphql";
      repo = "graphql-js";
      rev = "v17.0.0-alpha.2";
      sha256 = "sha256-y55SNiMivL7bRsjLEIpsKKyaluI4sXhREpiB6A5jfDU=";
    };
    warp = fetchFromGitHub {
      owner = "seanmonstar";
      repo = "warp";
      rev = "v0.3.3";
      sha256 = "sha256-76ib8KMjTS2iUOwkQYCsoeL3GwBaA/MRQU2eGjJEpOo=";
    };
  };
  pname = "dep-tree";
  version = "0.20.3";
in
buildGoModule {
  inherit pname version;

  src = fetchFromGitHub {
    owner = "gabotechs";
    repo = pname;
    rev = "v${version}";
    hash = "sha256-w0t6SF0Kqr+XAKPNJpDJGDTm2Tc6J9OzbXtRUNkqp2k=";
  };

  vendorHash = "sha256-ZDADo1takCemPGYySLwPAODUF+mEJXsaxZn4WWmaUR8=";

  preCheck = ''
    substituteInPlace internal/tui/tui_test.go \
      --replace-fail /tmp/dep-tree-tests ${linkFarm "dep-tree_testDeps-farm" testDeps}
  '';

  meta = {
    description = "Tool for visualizing interconnectedness of codebases in multiple languages";
    longDescription = ''
      dep-tree is a tool for interactively visualizing the complexity of a code base.
      It helps analyze the interconnectedness of the codebase and create goals to improve maintainability.
    '';
    homepage = "https://github.com/gabotechs/dep-tree";
    changelog = "https://github.com/gabotechs/dep-tree/releases/tag/v${version}";
    license = lib.licenses.mit;
    maintainers = with lib.maintainers; [ birdee ];
    mainProgram = "dep-tree";
  };
}