Search Results

Search: Posts Made By: sai2013
7,788
Posted By hanson44
Back to previous simple solution, yes there was a...
Back to previous simple solution, yes there was a glitch. Sorry about that. wc prints the file name, which I forgot. Here is correct version. Try this, see if it works:

while sleep 10; do
grep...
3,198
Posted By DGPickett
sed -n 's|.*<port> *\(.*[^ ]\) *</port>.*|\1|p'...
sed -n 's|.*<port> *\(.*[^ ]\) *</port>.*|\1|p' ../cfg.xmNarrative: If you find a line with '<PORT>', optional spaces, some not-space-value, optional spaces and '</port>', turn the entire line into...
3,198
Posted By Jotne
Here is how you assign output to a variable. ...
Here is how you assign output to a variable.
var=$(sed -n 's|<port>\(.*\)</port>|\1|p' ../cfg.xml)

If you post the input and how you like the output would be, it would be more easy to give you a...
Showing results 1 to 3 of 3

 
All times are GMT -4. The time now is 04:32 PM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy