xeals
7959b877d9
This commit moves a lot of the heavy lifting out of callPackage and back into regular import, following conventions from upstream Nixpkgs. It allows for a clearer and less magic definition of new packages, particularly by downstream, as well, by exposing the *Build package callers in the attribute set.
34 lines
749 B
Nix
34 lines
749 B
Nix
{ lib
|
|
, newScope
|
|
, stdenv
|
|
, fetchzip
|
|
|
|
, variant
|
|
}:
|
|
|
|
let
|
|
|
|
mkJetbrainsPlugins = import ../applications/editors/jetbrains/common-plugins.nix {
|
|
inherit lib stdenv fetchzip;
|
|
};
|
|
|
|
mkIdeaPlugins = import ../applications/editors/jetbrains/idea-plugins.nix {
|
|
inherit lib stdenv fetchzip;
|
|
};
|
|
|
|
jetbrainsWithPlugins = import ../applications/editors/jetbrains/wrapper.nix {
|
|
inherit lib;
|
|
};
|
|
|
|
in lib.makeScope newScope (self: lib.makeOverridable ({
|
|
jetbrainsPlugins ? mkJetbrainsPlugins self
|
|
, ideaPlugins ? mkIdeaPlugins self
|
|
}: ({ }
|
|
// jetbrainsPlugins // { inherit jetbrainsPlugins; }
|
|
// ideaPlugins // { inherit ideaPlugins; }
|
|
// {
|
|
inherit variant;
|
|
jetbrainsWithPlugins = jetbrainsWithPlugins self variant;
|
|
})
|
|
) { })
|