-1

Below is the command used for getting the required string from the file.

cat xmlconfig.new |grep "id=\"build\""

< parameter id="build" >v6.0.9< /parameter >

I want the v6.0.9 value from the above result, in such a way that it tokenizes according to the bracket, not according to word position

I do not have xml parser installed on my machine and I do not have admin access

I want to know if it can be done without using XML parser

Tiny Jaguar
  • 433
  • 3
  • 12
  • 30

1 Answers1

1

Use a proper XML parser, e.g. xsh:

open xmlconfig.new ;
echo //parameter[@id='build'] ;
choroba
  • 231,213
  • 25
  • 204
  • 289