From: Rudolf Sykora <rudolf.sykora@gmail.com>
To: Fans of the OS Plan 9 from Bell Labs <9fans@9fans.net>
Subject: [9fans] watching plumber
Date: Sat, 13 Mar 2010 00:25:20 +0100 [thread overview]
Message-ID: <a560a5d01003121525k2b44f2ck486e97e0814dcd0e@mail.gmail.com> (raw)
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
next reply other threads:[~2010-03-12 23:25 UTC|newest]
Thread overview: 14+ messages / expand[flat|nested] mbox.gz Atom feed top
2010-03-12 23:25 Rudolf Sykora [this message]
2010-03-12 23:54 ` erik quanstrom
2010-03-13 0:16 ` Rudolf Sykora
2010-03-13 0:39 ` erik quanstrom
2010-03-13 8:19 ` Rudolf Sykora
2010-03-13 10:45 ` Rudolf Sykora
2010-03-13 15:31 ` erik quanstrom
2010-03-13 17:14 ` Rudolf Sykora
2010-03-13 19:18 ` Rudolf Sykora
2010-03-13 23:05 ` erik quanstrom
2010-03-14 15:55 ` Rudolf Sykora
2010-03-14 20:11 ` erik quanstrom
2010-03-15 4:53 ` Anthony Sorace
2010-03-18 15:34 ` erik quanstrom
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=a560a5d01003121525k2b44f2ck486e97e0814dcd0e@mail.gmail.com \
--to=rudolf.sykora@gmail.com \
--cc=9fans@9fans.net \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).