nix-community / nix-eval-jobs

Parallel nix evaluator with a streamable json output [maintainers @Mic92, @adisbladis]
GNU General Public License v3.0
157 stars 31 forks source link

feat: add `--apply` flag #332

Open ysndr opened 1 month ago

ysndr commented 1 month ago

Allow applying every eval'ed drv to a provided nix expression to evaluate arbitrary fields.

EXAMPLE

% ./result/bin/nix-eval-jobs --flake github:NixOS/patchelf#hydraJobs \
  --apply \
  'drv: {
     version = if drv ? version then drv.version else null;
   }'
warning: `--gc-roots-dir' not specified
{"attr":"coverage","attrPath":["coverage"],"version":null}
{"attr":"patchelf-win32","attrPath":["patchelf-win32"],"version":"0.18.0"}
{"attr":"patchelf-win64","attrPath":["patchelf-win64"],"version":"0.18.0"}
{"attr":"release","attrPath":["release"],"version":null}
{"attr":"tarball","attrPath":["tarball"],"version":"0.18.0"}
Mic92 commented 3 weeks ago

@mergify rebase

mergify[bot] commented 3 weeks ago

rebase

✅ Branch has been successfully rebased

Mic92 commented 3 weeks ago

That crash looks legit. Do you have issues reproducing this locally?

ysndr commented 3 weeks ago

I don't remember that failing Will have a look later