Skip to content

nix-build --hash output isn't machine-parseable #1172

@dezgeg

Description

@dezgeg

The last 2 lines of output of e.g. nix-build --hash -A fio.src with a random sha256 value are:

build produced path ‘/nix/store/1ddvn536mgycflb48m23r8w4d01bzvkq-fio-fio-2.12-src’ with sha256 hash ‘1m0fx0x1v2375vyxhd2i12b9w1qy4yh75f6qhwlcr78himcsmpp9’
/nix/store/bcmckd9vn7gyrdyic5lyic01b5j3a5l2-fio-fio-2.12-src

That is, the useful value, 1m0fx0x1v2375vyxhd2i12b9w1qy4yh75f6qhwlcr78himcsmpp9 is only present in the stderr/build log. The line printed to stdout (the last one) is actually useless as it's presumably the "temporary" output path used before the hash is known.

Metadata

Metadata

Assignees

Labels

No fields configured for issues without a type.

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions