Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
compare two JSONs with jq #json #jq
@theArtechnology

This comment has been minimized.

Copy link

@theArtechnology theArtechnology commented Dec 8, 2020

How to compare by key ?

@delrioe

This comment has been minimized.

Copy link

@delrioe delrioe commented Mar 2, 2021

You can use: diff <(jq 'keys' file1.json) <(jq 'keys' file2.json)
This will just give you the list of keys that are different.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment