about summary refs log tree commit diff stats
path: root/pkgs/projectdo/default.nix
blob: b80de9510b5712eb069005b76a19de92cddcb6a5 (plain)
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
{ lib
, stdenv
, fetchFromGitHub
, ncurses
, nodejs
, pnpm
, yarn
, just
,
}:
let
  rev = "27c6fbc7fa534ce891db75361f2d2a27db64bb63";
in
stdenv.mkDerivation rec {
  pname = "projectdo";
  version = "unstable-2025-03-08";

  src = fetchFromGitHub {
    owner = "paldepind";
    repo = "projectdo";
    inherit rev;
    hash = "sha256-ZBAzHo7/Sy8uyjWganSFs/uOJkmuDP8WxU3WVGttPTo=";
  };

  dontConfigure = true;
  dontBuild = true;

  doCheck = true;
  checkPhase = ''
    make test
  '';

  nativeBuildInputs = [
    ncurses
    nodejs
    pnpm
    yarn
    just
  ];

  installPhase = ''
    make PREFIX=$out install
    install -D functions/* -t $out/share/fish/vendor_functions.d
    install -D completions/* -t $out/share/fish/vendor_completions.d
  '';

  meta = {
    description = "Context-aware single-letter project commands to speed up your terminal workflow";
    homepage = "https://github.com/paldepind/projectdo";
    license = lib.licenses.gpl3Only;
    maintainers = with lib.maintainers; [ alanpearce ];
    mainProgram = "projectdo";
    platforms = lib.platforms.all;
  };
}