[forge-dev] Bug on XML indentation?

George Gastaldi ggastald at redhat.com
Wed Jan 25 11:13:18 EST 2017


This looks like a bug indeed. Mind opening a JIRA and perhaps providing a
PR on https://github.com/forge/xml-parser? :)

Thanks!

Em 25 de jan de 2017 14:07, "Alex Soto Bueno" <asotobue at redhat.com>
escreveu:

> Hi I am generating an XML file in an addon using:
>
> XMLParser.toXMLString(xml);
>
> The node I am creating is done:
>
> xml.getOrCreate("extension at qualifier=" + qualifier)
>               .getOrCreate("property at name=" + key)
>               .text(value);
>
> were value is a yaml-like expression.
>
> The problem is that the resulting XML is not well indented:
>
> <?xml version="1.0" encoding="UTF-8" standalone="no"?>
> <arquillian xmlns="http://jboss.org/schema/arquillian" xmlns:xsi="
> http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="
> http://jboss.org/schema/arquillian
> http://jboss.org/schema/arquillian/arquillian_1_0.xsd">
>   <extension qualifier="algeron-consumer">
>     <configuration>
>       <property name="publishConfiguration">
> provider: folder
> outputFolder: /tmp/contracts
> contractsFolder: target/pacts
> </property>
>     </configuration>
>   </extension>
> </arquillian>
>
> I can understand that YAML thing is not correctly formatted but notice that
> the closing </property> tag is not correctly indented.
>
> Any idea?
>
> Alex.
> _______________________________________________
> forge-dev mailing list
> forge-dev at lists.jboss.org
> https://lists.jboss.org/mailman/listinfo/forge-dev
>


More information about the forge-dev mailing list