[diffoscope] Schema of diffoscope JSON output
Chris Lamb
chris at reproducible-builds.org
Wed Jan 15 18:00:15 UTC 2025
Hello Aman,
> I want to know if there is a schema for JSON output from diffoscope. I
> have understood that it always contains 'source1' and 'source2'.
> However, they can either mean the actual source files that are being
> diff-ed or the name of the tool that is run on the files before being
> diff-ed.
No, there is not a defined JSON schema á la json-schema.org (or
similar) beyond what you have observed. :)
The "source1" and "source2" fields are essentially free-form text
descriptions — as you outline, sometimes they are filenames and
sometimes they are descriptions of the tool being used to format some
difference.
Do remember that because of the way that diffoscope recursively
unpacks archives, you cannot rely on any filenames listed in these
fields being resolvable on the filesystem anyway, so it is unclear
what would be gained if this was somehow more... 'strict'.
Is there a particular problem you are trying to solve here? Your
question suggests there might be.
Best wishes,
--
o
⬋ ⬊ Chris Lamb
o o reproducible-builds.org 💠
⬊ ⬋
o
More information about the diffoscope
mailing list