Bug 977977 - javapackages-tools: POM editing macros should preserve formatting of injected XML
javapackages-tools: POM editing macros should preserve formatting of injected...
Product: Fedora
Classification: Fedora
Component: javapackages-tools (Show other bugs)
Unspecified Unspecified
medium Severity unspecified
: ---
: ---
Assigned To: Mikolaj Izdebski
Fedora Extras Quality Assurance
: FutureFeature, Triaged, Upstream
Depends On:
  Show dependency treegraph
Reported: 2013-06-25 13:31 EDT by Mikolaj Izdebski
Modified: 2013-09-12 01:41 EDT (History)
6 users (show)

See Also:
Fixed In Version: 3.0.3-1
Doc Type: Enhancement
Doc Text:
Story Points: ---
Clone Of:
Last Closed: 2013-09-12 01:41:25 EDT
Type: Bug
Regression: ---
Mount Type: ---
Documentation: ---
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---

Attachments (Terms of Use)

  None (edit)
Description Mikolaj Izdebski 2013-06-25 13:31:17 EDT
Description of problem:
Currenty POM macros that accept arbitrary XML to be injected (including %pom_xpath_inject, but also %pom_add_dep and %pom_add_plugin) remove unnecessary white spaces from XML code being injected.

To improve readability of patched POMs original indentation should be preserved. Alternatively injected XML could be reformated according to common practices.

Version-Release number of selected component (if applicable):
Comment 1 Mikolaj Izdebski 2013-08-09 07:37:31 EDT
Feature implemented upstream in commit b072410
Comment 2 Mikolaj Izdebski 2013-09-12 01:40:30 EDT
Verified in rawhide.

$ rpm -q javapackages-tools

$ cat pom.xml

$ (pom_add_dep foo:bar)

$ cat pom.xml
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
		<!-- begin of code added by maintainer -->
		<!-- end of code added by maintainer -->
Comment 3 Mikolaj Izdebski 2013-09-12 01:40:40 EDT
Fixed in javapackages-tools-3.0.3-1
Comment 4 Mikolaj Izdebski 2013-09-12 01:41:25 EDT
I believe that this bug is fixed in javapackages-tools-3.0.3-1,
which is available in Fedora Rawhide, so I am closing this bug now.

The build containing the fix can be found at Koji:

Note You need to log in before you can comment on or make changes to this bug.