Last active
March 3, 2016 09:50
-
-
Save lkdjiin/fef3645cae906fd6cd85 to your computer and use it in GitHub Desktop.
XML prettify
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env bash | |
# xmllint comes from the libxml2-utils package. | |
if [ $# -eq 1 ]; then | |
cat $1 | xmllint --format - | |
else | |
printf "\n Usage xml-pretty file.xml\n\n" | |
exit 1 | |
fi |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment