-----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1
Casey T. Deccio wrote:
| On Tue, 2004-07-13 at 14:34, Jason Holt wrote: | |>Of course, if I wanted to be pedantic, I could suggest that |>you s/:\%s\/\/\/ing/:\%s\/\/\//, since vim reports "trailing characters" if |>you :%s///ing. |> | | | By the way, when you're replace string has a lot of '/'s, there is no | need to escape them. Instead, try using a different character as your | delimiter: | | s/\/path\/to\/file/\/new\/path/ | | is equivalent to | | s:/path/to/file:/new/path: | | or even | | s)/path/to/file)/new/path) | | Casey
In perl (and many other languages) regular expressions this is valid, but in vim's :substitute (which is what :s is short for) ... it IS valid! Wow and cool. For some reason I'd thought vim would be more tied to the exact /// syntax.
/me raises his vim respectometer level from 95% to 97%...
Thanks, Casey :)
Jacob
- -- "Concern for man and his fate must always form the chief interest of all technical endeavors ... Never forget this in the midst of your diagrams and equations." - Einstein -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.2.1 (MingW32) Comment: Using GnuPG with Thunderbird - http://enigmail.mozdev.org
iD4DBQFA9FQplzgpdZsoHrcRAhJHAJdAevMNAWc8E7SNrD3Mvi1cBBncAJ9oJLW2 b+tsFMZoS/yR3l35PsYCRQ== =t7yu -----END PGP SIGNATURE-----
____________________
BYU Unix Users Group http://uug.byu.edu/ ___________________________________________________________________
List Info: http://uug.byu.edu/cgi-bin/mailman/listinfo/uug-list
