I am writing documents in XML using Arbortext. I would like to make a list of all referenced graphics using grep. Here's what I tried:
* Save the xml file as .txt.
* Grep for file.loc="*" in hopes of finding all strings like this:
file.loc="../graphics/online/image.jpg"
file.loc="../graphics/print/image.eps"
Grep does find all of these references, but it appears to return everything in the line, which includes a whole lot of markup and content that comes before and after the text reference. I believe this is because XML doesn't use line breaks in a meaningful way,
Is there a way to get grep to return only the text string I am specifying?
Any help would be greatly appreciated!
* Save the xml file as .txt.
* Grep for file.loc="*" in hopes of finding all strings like this:
file.loc="../graphics/online/image.jpg"
file.loc="../graphics/print/image.eps"
Grep does find all of these references, but it appears to return everything in the line, which includes a whole lot of markup and content that comes before and after the text reference. I believe this is because XML doesn't use line breaks in a meaningful way,
Is there a way to get grep to return only the text string I am specifying?
Any help would be greatly appreciated!