Skip to content

Commit

Permalink
nix-eval-jobs should check hydraJobs and then checks with flakes
Browse files Browse the repository at this point in the history
  • Loading branch information
Ericson2314 committed Feb 7, 2025
1 parent ac35aa4 commit 40fbc55
Showing 1 changed file with 10 additions and 1 deletion.
11 changes: 10 additions & 1 deletion src/script/hydra-eval-jobset
Original file line number Diff line number Diff line change
Expand Up @@ -358,7 +358,16 @@ sub evalJobs {
my @cmd;

if (defined $flakeRef) {
@cmd = ("nix-eval-jobs", "--flake", $flakeRef . '#hydraJobs');
my $nix_expr =
"let " .
"flake = builtins.getFlake (toString \"$flakeRef\"); " .
"in " .
"flake.hydraJobs " .
"or flake.checks " .
"or (throw \"flake '$flakeRef' does not provide any Hydra jobs or checks\")";

print "nix-eval-jobs --expr $nix_expr";
@cmd = ("nix-eval-jobs", "--expr", $nix_expr);
} else {
my $nixExprInput = $inputInfo->{$nixExprInputName}->[0]
or die "cannot find the input containing the job expression\n";
Expand Down

0 comments on commit 40fbc55

Please sign in to comment.