mirror of
https://gitlab.com/TECHNOFAB/nix-gitlab-ci.git
synced 2025-12-11 17:50:08 +01:00
26 lines
715 B
Nix
26 lines
715 B
Nix
args: let
|
|
# allow passing just pkgs aswell for convenience
|
|
lib = args.lib or args.pkgs.lib;
|
|
# makes it optional to pass if it's not explicitly needed
|
|
pkgs = args.pkgs or (throw "[nix-gitlab-ci] pkgs argument was used but not set, please pass it");
|
|
inherit (lib) evalModules;
|
|
|
|
impl = import ./impl {inherit lib pkgs cilib;};
|
|
|
|
cilib = {
|
|
inherit (impl) helpers modules mkPipeline mkJobRun mkJobDeps mkJobPatched;
|
|
utils = import ./utils.nix {inherit pkgs;};
|
|
version = builtins.readFile ./VERSION;
|
|
|
|
mkCI = config:
|
|
(evalModules {
|
|
modules = [
|
|
cilib.modules.nixCiSubmodule
|
|
{
|
|
inherit config;
|
|
}
|
|
];
|
|
}).config;
|
|
};
|
|
in
|
|
cilib
|