Hello,

I wanted to add a plumbing rule. I added this:

type is text
data matches '[^{}]+'
data matches '(figs/([a-zA-Z0-9[\].-_]*/)*)([a-zA-Z0-9.-_]+)'
arg isdir $1
plumb start grep $2 $1/_source | sed -e 's/\.eps/.g/' | \
        plumb -i -d edit

However, it doesn't work. Is there any simple way how one can analyze
what is wrong? I.e. to see that some rules are matched, others not, so
that one can get the idea where the problem is (how far in the rules
one gets)?

Also. When having a rule like this

data matches '(abc(def)*)(ghi)'

what is going to be in $1, $2... Is ghi the contents of $2 or not?

The plumber's behaviour I want to achieve is quite difficult to
explain, nonetheless:
for a text in an editor like
{figs/10[CuNi]/Cxy}
I want to find a line in figs/10[CuNi]/_source containing Cxy, it will
be something like /abc/Cxy.eps and I really want to open a file
/abc/Cxy.g in the editor.

Thanks for any comments!
Ruda

Reply via email to