URL:
<http://savannah.gnu.org/bugs/?29827>
Summary: 2.6.3 FEATURE REQUEST: Extend --only-matching to
accept submatch
Project: grep
Submitted by: jaalto
Submitted on: Sat 08 May 2010 03:42:03 PM EEST
Category: None
Severity: 3 - Normal
Item Group: None
Status: None
Privacy: Public
Assigned to: None
Open/Closed: Open
Discussion Lock: Any
_______________________________________________________
Details:
Manual page reads:
-o, --only-matching
Print only the matched (non-empty) parts of a matching
line,
with each such part on a separate output line.
FEATURE REQUEST
Extend the option to accept additional numeric argument to control the
submatch returned. (By default 0). This woudl make it possible to run:
echo "Program version 1.12" | grep -E -o 1 "Program.*([0-9.]+)"
_______________________________________________________
Reply to this item at:
<http://savannah.gnu.org/bugs/?29827>
_______________________________________________
Message sent via/by Savannah
http://savannah.gnu.org/