[patched]: Configcompare
xmllint --format --c14n file1.xml > file1_normalized.xml Now compare the normalized files:
#!/bin/bash # Usage: configcompare file1.json file2.json # configcompare file1.yaml file2.yaml FILE1=$1 FILE2=$2 EXT="$FILE1##*." configcompare
jq 'del(.metadata.generated, .timestamp)' file1.json xmllint --format --c14n file1
diff -u file1_normalized.json file2_normalized.json Better yet, use a structural diff tool that understands paths: xmllint --format --c14n file1.xml >