nur-packages

My NUR packages
git clone git://git.sikmir.ru/nur-packages
Log | Files | Refs | README | LICENSE

default.nix (954B)


      1 {
      2   lib,
      3   stdenv,
      4   fetchfromgh,
      5   jre,
      6   makeWrapper,
      7 }:
      8 
      9 stdenv.mkDerivation (finalAttrs: {
     10   pname = "qstudio";
     11   version = "2.54";
     12 
     13   src = fetchfromgh {
     14     owner = "timeseries";
     15     repo = "qstudio";
     16     name = "qstudio.jar";
     17     hash = "sha256-NN2pkAjlwTbq25AafD06NMoAaOknW5nimya2zi+aMBQ=";
     18     version = finalAttrs.version;
     19   };
     20 
     21   nativeBuildInputs = [ makeWrapper ];
     22 
     23   buildInputs = [ jre ];
     24 
     25   dontUnpack = true;
     26 
     27   installPhase = ''
     28     install -dm755 $out/bin
     29     install -Dm644 $src $out/share/java/${finalAttrs.src.name}
     30 
     31     makeWrapper ${jre}/bin/java $out/bin/qstudio \
     32       --add-flags "-jar $out/share/java/${finalAttrs.src.name}"
     33   '';
     34 
     35   meta = {
     36     description = "SQL Analysis Tool";
     37     homepage = "https://www.timestored.com/qstudio/";
     38     sourceProvenance = with lib.sourceTypes; [ binaryBytecode ];
     39     license = lib.licenses.asl20;
     40     maintainers = [ lib.maintainers.sikmir ];
     41     platforms = jre.meta.platforms;
     42   };
     43 })