Is there any formal way or known way to canonicalize an xml file to generate diffs?
There seems to be many questions WRT tool to generate diffs between xmls, but there wasn’t this question yet, so anyone who knows this show me a link or paste any example anyone already solved this problem.
Canonicalizing an xml file means,
- Jenkins: The result file for the metric 'JUnit' is not valid. The result file has been skipped
- Android studio doesn't recognize AndroidManifest.xml as part of project when use git
- Automatically merge two XML files by selecting both conflicting lines
- What features make a file format friendly to VCS?
- How can I merge mysql workbench (*.mwb) diagram with git If I know how to make a text representation of it?
- Fill an XML file with test data
- reordering the appearance of attributes
- reordering the appearance of tags (selectable by command line option)
- insert line ending(CR/CR+LF/LF) if there isn’t at the end of a close tag
- insert indentation tab(space)
- remove redundant spaces and line endings
And then you can cleanly diff the xml files to see which part was updated.
2 Solutions collect form web for “Is there any formal way or known way to canonicalize an xml file to generate diffs?”
XMLStarlet has a canonicalization mode (
Instead, you could use the xmldiff tool: Using the XML Diff and Patch Tool in Your Applications
The XML Diff and Patch GUI Tool