On 03/10/2015 01:17 AM, Mikolaj Izdebski wrote:
On 03/09/2015 09:10 PM, Orion Poplawski wrote:
> Is it possible to use %pom_xpath_remove (or similar) to edit an arbitrary xml
> file? I'd like to remove from:
Yes, it should work.
> releng/org.eclipse.ptp.repo/category.xml:
>
> <site>
> ...
> <feature url="features/org.eclipse.ptp.rdt.sync.fortran_0.0.0.jar"
> id="org.eclipse.ptp.rdt.sync.fortran" version="0.0.0">
> <category name="Remote Development Tools"/>
> </feature>
> ...
> </site>
I've just verified it with:
$ cat /tmp/feature.xml
<site>
<feature url="features/org.eclipse.ptp.rdt.sync.fortran_0.0.0.jar"
id="org.eclipse.ptp.rdt.sync.fortran" version="0.0.0">
<category name="Remote Development Tools"/>
</feature>
</site>
$ python3 /usr/share/java-utils/pom_editor.py pom_xpath_remove feature
/tmp/feature.xml
$ cat /tmp/feature.xml
<site>
</site>
Ah, sorry, I should have been a little more clear. There are several
<feature> items, but I only want to remove that specific one. I don't know
how to name that.
Thanks!
--
Orion Poplawski
Technical Manager 303-415-9701 x222
NWRA, Boulder/CoRA Office FAX: 303-415-9702
3380 Mitchell Lane orion(a)nwra.com
Boulder, CO 80301
http://www.nwra.com