Sponsored Content
Top Forums Shell Programming and Scripting Replacing a value in all xml's Post 302893074 by punpun66 on Monday 17th of March 2014 10:10:31 AM
Old 03-17-2014
Wrench Replacing a value in all xml's

Hi Folks,

Could you please advise what will be the unix command to replace the character in all xml's under a particular directory for example

let say I rite now at the following below location

Code:
$ cd /opt/apr/rt/conf

now under conf there are so many xml's and in those xml's i want to replace
value ABCD with value TRYU , so please advise what will be the appropriate unix command to achieve this. Thanks in advanceSmilie
 

10 More Discussions You Might Find Interesting

1. Shell Programming and Scripting

replacing string in an XML file

Hi all, I need to replace string in XML file..XML file like <dependency> <groupId>fr.orange.portail.ear</groupId> <artifactId>_AdminServicesEAR</artifactId> <version>1.0.0-20080521.085352-1</version> <type>ear</type> </dependency> <dependency> ... (2 Replies)
Discussion started by: subin_bala
2 Replies

2. Shell Programming and Scripting

Replacing the last record in xml with different tags

I have special requirement, my system provided the xml file as below(available xml file) and I need to convert it as below desired xml file. is it possible thru shell scripts or awk? What I need is : my available xml contains number of records with tags <RevenueAmounts>, the last of record is... (6 Replies)
Discussion started by: LinuxLearner
6 Replies

3. Shell Programming and Scripting

Replacing number between xml tags with ksh shell script

Hallo, im basically a complete noob on shell scripting and im trying to replace or rather add 1 to a number between xml tags. The xml basically has a tag somewhere that looks like this: <tag>12345678901234</tag> Now i want to replace the number between the tags. And i want the file to... (6 Replies)
Discussion started by: Demoric
6 Replies

4. Shell Programming and Scripting

Replacing part of XML code inside comment tags

Hello! I'd like to modify custom values in a XML config file between comment tags using bash script. <feature> <keyboardshortcut>C-m</keyboardshortcut> <option1>disabled</option2> <option2>enabled</option2> </feature> <!-- bash script features START --> <feature> ... (2 Replies)
Discussion started by: prism1
2 Replies

5. Shell Programming and Scripting

Reading XML and replacing a string

Hi All, My thanks in advance for you guys reading this and for any posts. I'm having 100 XML files, I need script which replace a specific string. It must be incrementing in 100 xml files.. Sample XML files: <hwIPHostName type="attrib">DEMO1</hwIPHostName> I need Demo1 to be... (4 Replies)
Discussion started by: karty2129
4 Replies

6. Shell Programming and Scripting

How to add the multiple lines of xml tags before a particular xml tag in a file

Hi All, I'm stuck with adding multiple lines(irrespective of line number) to a file before a particular xml tag. Please help me. <A>testing_Location</A> <value>LA</value> <zone>US</zone> <B>Region</B> <value>Russia</value> <zone>Washington</zone> <C>Country</C>... (0 Replies)
Discussion started by: mjavalkar
0 Replies

7. Shell Programming and Scripting

Shell Command to compare two xml lines while ignoring xml tags

I've got two different files and want to compare them. File 1 : HTML Code: <response ticketId="944" type="getQueryResults"><status>COMPLETE</status><description>Query results fetched successfully</description><recordSet totalCount="1" type="sms_records"><record... (1 Reply)
Discussion started by: Shaishav Shah
1 Replies

8. Shell Programming and Scripting

Replacing a file in between a XML file

I am having XML file,i need to replace a range of string and replace with a file,Pls anyone help, My Xml file looks like </Order><PersonInfoShipTo AddressID="446311709" AddressLine1="" AddressLine2="" AddressLine3="" AddressLine4="" AddressLine5="" AddressLine6="" AlternateEmailID="" Beeper=""... (2 Replies)
Discussion started by: mohanalakshmi
2 Replies

9. Shell Programming and Scripting

Replacing a particular word with another word in all the xml's under a particular directory with sed

Hi Folks, Could you please advise what will be the SED command to replace a word in all xml's under a particular directory for example let say I rite now at the following below location $ cd /ter/rap/config now under config directory there will be lots of xml file , now my objective is to... (1 Reply)
Discussion started by: punpun66
1 Replies

10. Shell Programming and Scripting

Replacing tab value in xml file

Hi I am working on xml file. I have to make sure below lines containing values within quotes are replaced by some character like "-". Below are different lines in xml file. Pattern 1: <Connector port=.... ..... keystoremyPass="xxx" /> Pattern 2: myword="xxxxx" ... (11 Replies)
Discussion started by: krsnadasa
11 Replies
POM_ADD_PARENT(7)						Java Packages Tools						 POM_ADD_PARENT(7)

NAME
pom_add_parent - add parent POM reference to POM file SYNOPSIS
%pom_add_parent groupId*:*artifactId[*:*version] [POM-location] DESCRIPTION
This macro patches specified POM file adding a reference to parent POM with specified groupId, artifactId and version. groupId and artifactId are identifiers of Maven group and artifact of the POM to be referenced as parent POM. They must be specified. If version is not specified then default value of "any" is used. POM location can be either a full path to the POM file, or a path to the directory containing pom.xml. If POM location is not given then pom.xml from current working directory is used. EXAMPLES
%pom_add_parent foo:bar baz - this call adds reference to parent POM artifact foo:bar to baz/pom.xml file. BUGS
If specified POM has already a reference to parent POM this macro will not alter or remove it. Instead a second reference will be added. This is usually not the expected behavior as it results in creating invalid POM file. In order to replace existing parent POM reference, pom_set_parent(7) should be used instead. AUTHOR
Written by Mikolaj Izdebski. REPORTING BUGS
Bugs should be reported through Red Hat Bugzilla at http://bugzilla.redhat.com/. SEE ALSO
pom_add_dep(7), pom_add_plugin(7), pom_disable_module(7), pom_remove_dep(7), pom_remove_parent(7), pom_remove_plugin(7), pom_set_parent(7), pom_xpath_inject(7), pom_xpath_remove(7), pom_xpath_replace(7), pom_xpath_set(7). JAVAPACKAGES
06/10/2014 POM_ADD_PARENT(7)
All times are GMT -4. The time now is 09:48 AM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy