Maurice Lombardi a écrit :
Frank Heckenbach a écrit :
Maurice Lombardi wrote:
! ADD_RTS_PARENT_DIR = sed -e 's,-B([^/]),-B../../\1,g;s,^([^/][^ ]*),../../\1,'` ! ADD_RTS_PARENT_DIR = sed -e 's,-B([^/][^:]),-B../../\1,g;s,^([^/][^:][^ ]*),../../\1,'`
I need a great supply of asprin nearby when trying to decipher those sed scripts
Got the asprin. The logics is (extracted from rx.info)
For example, the character `*' is used to indicate that the preceeding element of a regexp may be repeated 0, 1, or more times.
0 is the problem. It does not excludes the case where : is the second character. And IIRC the + which would mean at least 1 is not understood by all sed's (notably the djgpp one whe had sometimes ago when I tried to figure that out. May be a more recent release ...)
Hope this helps
Maurice