sed numbered fields don't start from parenthesis
blind Pete <[email protected]>
| Newsgroups | gmane.comp.gnu.utils.bugs |
|---|---|
| Message-ID | <20141002224144.627d71f1@PPlive> |
Hi, I believe that the output from the following should be "Sep", not "28th_Sep". The result can be changed by adding a ".*" to the start of the search string, but I don't think that that should be necessary. Removing the trailing ".*" also produces odd results. Using Ubuntu 12.04 LTS. $ echo 28th_September_2014 | sed "s/\(sep\).*/\1/i" 28th_Sep $ sed --version GNU sed version 4.2.1 Copyright (C) 2009 Free Software Foundation, Inc. This is free software; see the source for copying conditions. There is NO warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE, to the extent permitted by law. GNU sed home page: <http://www.gnu.org/software/sed/>. General help using GNU software: <http://www.gnu.org/gethelp/>. E-mail bug reports to: <[email protected]>. Be sure to include the word ``sed'' somewhere in the ``Subject:'' field. $ -- testing bP
signature.asc
(application/pgp-signature, 198 B)
-----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.11 (GNU/Linux) iEYEARECAAYFAlQtSAgACgkQwRfXamhmx7/VjwCglu/1Pm0JvRmLHqNQ2WLjM0A3 lZMAnR3EAbG/sI09Vg2Qdy/8lC7UCZjl =NjPF -----END PGP SIGNATURE-----