nur-packages/pkgs/applications/editors/jetbrains/build-plugin.nix
xeals d985759753
Some checks reported errors
continuous-integration/drone/push Build was killed
Port builds from nixos configuration
2020-10-15 19:05:13 +11:00

31 lines
527 B
Nix

{ stdenv
, fetchzip
, jetbrainsPlatforms
}:
{ pluginId
, pname
, version
, versionId
, sha256
, filename ? "${pname}-${version}.zip"
}:
stdenv.mkDerivation {
inherit pname version jetbrainsPlatforms;
src = fetchzip {
inherit sha256;
url = "https://plugins.jetbrains.com/files/${toString pluginId}/${toString versionId}/${filename}";
};
installPhase = ''
mkdir $out
cp -r * $out/
'';
meta = {
homepage = "https://plugins.jetbrains.com/plugin/${pluginId}-${stdenv.lib.toLower pname}";
};
}