Hi Eric,
> at which point, ignore-removed contains:
> test-freadptr.c
> test-freadptr.sh
> test-freadptr2.c
> test-freadptr2.sh
> test-freadseek.c
> test-freadseek.sh
> test-memchr2.c
Looks ok. The directory part of the filename is removed at the point, because
it's updating the tests/.gitignore file.
> and sed-ignore-removed contains:
> /^test-freadptr.c/d
> /^test-freadptr.sh/d
> /^test-freadptr2.c/d
> /^test-freadptr2.sh/d
> /^test-freadseek.c/d
> /^test-freadseek.sh/d
> /^test-memchr2.c/d
ok so far.
> /^/test-freadptr.c/d
This should be /^\/test-freadptr.c/d
This may be a difference between sh or sed versions. What's the result of these
two sets of commands for you?
$ doubly_escaped_anchor='\\/'
$ echo 'test-freadseek.sh' | \
sed -e 's,/,\\/,g' -e "s,^,/^${doubly_escaped_anchor}," -e 's,$,\$/d,'
$ triply_escaped_anchor='\\\/'
$ echo 'test-freadseek.sh' | \
sed -e 's,/,\\/,g' -e "s,^,/^${triply_escaped_anchor}," -e 's,$,\$/d,'
For me, with bash and sed-4.1.5, the result of both is
/^\/test-freadseek.sh$/d
And on your side?
Bruno