remove deleted targets
All checks were successful
Hydra jobsets Hydra build #33343 of procyos:.jobsets:jobsets
All checks were successful
Hydra jobsets Hydra build #33343 of procyos:.jobsets:jobsets
This commit is contained in:
parent
ac69afd054
commit
f82a3ef77e
2 changed files with 84 additions and 88 deletions
162
default.nix
162
default.nix
|
@ -1,18 +1,20 @@
|
|||
{
|
||||
nixpkgs,
|
||||
extra-math-prs,
|
||||
rand-testsuite-prs,
|
||||
rust-template-prs,
|
||||
}: let
|
||||
pkgs = import nixpkgs {};
|
||||
prs = with pkgs.lib;
|
||||
concatLists (map (f: attrValues (builtins.fromJSON (builtins.readFile f))) [
|
||||
extra-math-prs
|
||||
rand-testsuite-prs
|
||||
rust-template-prs
|
||||
]);
|
||||
prJobsets = with pkgs.lib;
|
||||
listToAttrs (map (pr: {
|
||||
}:
|
||||
let
|
||||
pkgs = import nixpkgs { };
|
||||
prs =
|
||||
with pkgs.lib;
|
||||
concatLists (
|
||||
map (f: attrValues (builtins.fromJSON (builtins.readFile f))) [
|
||||
rust-template-prs
|
||||
]
|
||||
);
|
||||
prJobsets =
|
||||
with pkgs.lib;
|
||||
listToAttrs (
|
||||
map (pr: {
|
||||
name = "${pr.base.repo.name}-pr${toString pr.number}";
|
||||
value = {
|
||||
enabled = pr.state == "open";
|
||||
|
@ -21,10 +23,7 @@
|
|||
nixexprinput = "component";
|
||||
nixexprpath = "default.nix";
|
||||
checkinterval = 3600;
|
||||
schedulingshares =
|
||||
if pr.user.id == 1
|
||||
then 100
|
||||
else 10;
|
||||
schedulingshares = if pr.user.id == 1 then 100 else 10;
|
||||
enableemail = false;
|
||||
emailoverride = "";
|
||||
keepnr = 1;
|
||||
|
@ -37,70 +36,77 @@
|
|||
};
|
||||
}
|
||||
// (
|
||||
if hasPrefix "https://git.chir.rs/" pr.head.repo.clone_url
|
||||
then {
|
||||
gitea_status_repo = {
|
||||
type = "string";
|
||||
value = "component";
|
||||
emailresponsible = false;
|
||||
};
|
||||
gitea_repo_owner = {
|
||||
type = "string";
|
||||
value = head (splitString "/" pr.head.repo.full_name);
|
||||
emailresponsible = false;
|
||||
};
|
||||
gitea_repo_name = {
|
||||
type = "string";
|
||||
value = pr.head.repo.name;
|
||||
emailresponsible = false;
|
||||
};
|
||||
}
|
||||
else {}
|
||||
if hasPrefix "https://git.chir.rs/" pr.head.repo.clone_url then
|
||||
{
|
||||
gitea_status_repo = {
|
||||
type = "string";
|
||||
value = "component";
|
||||
emailresponsible = false;
|
||||
};
|
||||
gitea_repo_owner = {
|
||||
type = "string";
|
||||
value = head (splitString "/" pr.head.repo.full_name);
|
||||
emailresponsible = false;
|
||||
};
|
||||
gitea_repo_name = {
|
||||
type = "string";
|
||||
value = pr.head.repo.name;
|
||||
emailresponsible = false;
|
||||
};
|
||||
}
|
||||
else
|
||||
{ }
|
||||
);
|
||||
};
|
||||
})
|
||||
prs);
|
||||
projectJobsets = with pkgs.lib;
|
||||
listToAttrs (map (repo: {
|
||||
name = repo;
|
||||
value = {
|
||||
enabled = true;
|
||||
visible = true;
|
||||
description = repo;
|
||||
nixexprinput = "component";
|
||||
nixexprpath = "default.nix";
|
||||
checkinterval = 3600;
|
||||
schedulingshares = 100;
|
||||
enableemail = false;
|
||||
emailoverride = "";
|
||||
keepnr = 1;
|
||||
inputs = {
|
||||
component = {
|
||||
type = "git";
|
||||
value = "https://git.chir.rs/ProcyOS/${repo} main";
|
||||
emailresponsible = false;
|
||||
};
|
||||
gitea_status_repo = {
|
||||
type = "string";
|
||||
value = "component";
|
||||
emailresponsible = false;
|
||||
};
|
||||
gitea_repo_owner = {
|
||||
type = "string";
|
||||
value = "ProcyOS";
|
||||
emailresponsible = false;
|
||||
};
|
||||
gitea_repo_name = {
|
||||
type = "string";
|
||||
value = repo;
|
||||
emailresponsible = false;
|
||||
}) prs
|
||||
);
|
||||
projectJobsets =
|
||||
with pkgs.lib;
|
||||
listToAttrs (
|
||||
map
|
||||
(repo: {
|
||||
name = repo;
|
||||
value = {
|
||||
enabled = true;
|
||||
visible = true;
|
||||
description = repo;
|
||||
nixexprinput = "component";
|
||||
nixexprpath = "default.nix";
|
||||
checkinterval = 3600;
|
||||
schedulingshares = 100;
|
||||
enableemail = false;
|
||||
emailoverride = "";
|
||||
keepnr = 1;
|
||||
inputs = {
|
||||
component = {
|
||||
type = "git";
|
||||
value = "https://git.chir.rs/ProcyOS/${repo} main";
|
||||
emailresponsible = false;
|
||||
};
|
||||
gitea_status_repo = {
|
||||
type = "string";
|
||||
value = "component";
|
||||
emailresponsible = false;
|
||||
};
|
||||
gitea_repo_owner = {
|
||||
type = "string";
|
||||
value = "ProcyOS";
|
||||
emailresponsible = false;
|
||||
};
|
||||
gitea_repo_name = {
|
||||
type = "string";
|
||||
value = repo;
|
||||
emailresponsible = false;
|
||||
};
|
||||
};
|
||||
};
|
||||
};
|
||||
}) [
|
||||
"extra_math"
|
||||
"rand_testsuite"
|
||||
"rust-template"
|
||||
]);
|
||||
})
|
||||
[
|
||||
"rust-template"
|
||||
]
|
||||
);
|
||||
jobsets = prJobsets // projectJobsets;
|
||||
in {jobsets = pkgs.writeText "jobsets.json" (builtins.toJSON jobsets);}
|
||||
in
|
||||
{
|
||||
jobsets = pkgs.writeText "jobsets.json" (builtins.toJSON jobsets);
|
||||
}
|
||||
|
|
10
spec.json
10
spec.json
|
@ -35,16 +35,6 @@
|
|||
"value": "ci",
|
||||
"emailresponsible": false
|
||||
},
|
||||
"extra-math-prs": {
|
||||
"type": "giteapulls",
|
||||
"value": "git.chir.rs ProcyOS extra_math",
|
||||
"emailresponsible": false
|
||||
},
|
||||
"rand-testsuite-prs": {
|
||||
"type": "giteapulls",
|
||||
"value": "git.chir.rs ProcyOS rand_testsuite",
|
||||
"emailresponsible": false
|
||||
},
|
||||
"rust-template-prs": {
|
||||
"type": "giteapulls",
|
||||
"value": "git.chir.rs ProcyOS rust-template",
|
||||
|
|
Loading…
Reference in a new issue