about summary refs log tree commit diff
path: root/pkgs/servers/jetbrains/youtrack.nix
blob: c3680d76b96ea36040e34985b35ef239c066afac (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
{ lib, stdenv, fetchurl, makeWrapper, jre, gawk }:

stdenv.mkDerivation rec {
  pname = "youtrack";
  version = "2018.2.44329";

  jar = fetchurl {
    url = "https://download.jetbrains.com/charisma/${pname}-${version}.jar";
    sha256 = "1fnnpyikr1x443vxy6f7vlv550sbahpps8awyn13jpg7kpgfm7lk";
  };

  nativeBuildInputs = [ makeWrapper ];

  dontUnpack = true;

  installPhase = ''
    runHook preInstall
    makeWrapper ${jre}/bin/java $out/bin/youtrack \
      --add-flags "\$YOUTRACK_JVM_OPTS -jar $jar" \
      --prefix PATH : "${lib.makeBinPath [ gawk ]}" \
      --set JRE_HOME ${jre}
    runHook postInstall
  '';

  meta = with lib; {
    description = "Issue tracking and project management tool for developers";
    maintainers = with maintainers; [ yorickvp ];
    # https://www.jetbrains.com/youtrack/buy/license.html
    license = licenses.unfree;
  };
}