-
-
Save zed/6deb8175ed03647981c3 to your computer and use it in GitHub Desktop.
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
from bs4 import BeautifulSoup | |
s = """<?xml version="1.0" encoding="UTF-8" standalone="yes"?> | |
<!-- Data Junction generated file. | |
Macro type "1000" is reserved. --> | |
<djmacros> | |
<macro name="Test" type="5000" value="TestValue"> | |
<description>test</description> | |
</macro> | |
<macro name="AnotherTest" type="0" value="TestValue2"/> | |
<macro name="TestLocation" type="1000" value="C:\RandomLocation"> | |
<description> </description> | |
</macro> | |
<djmacros> | |
""" | |
soup = BeautifulSoup(s, 'xml') | |
print(repr(soup.prettify())) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment