From mboxrd@z Thu Jan 1 00:00:00 1970 Message-ID: <47dd21df91f37b7a9fc370e3d0eca85f@quanstro.net> From: erik quanstrom Date: Sun, 13 Jan 2008 13:19:33 -0500 To: 9fans@cse.psu.edu Subject: Re: [9fans] plumber rule for WikiWords In-Reply-To: <0801131802120.20246@cab.mteege.de> MIME-Version: 1.0 Content-Type: text/plain; charset="US-ASCII" Content-Transfer-Encoding: 7bit Topicbox-Message-UUID: 2d7ad4c0-ead3-11e9-9d60-3106f5b1d025 > I use the following plumbing rule to "emulate" wiki like functions in > acme: > > type is text > data matches '([A-Z]+[a-z]+[A-Z]+[a-z]+)*$' > data set wiki/$0.txt > plumb to edit > > Most of the time it works but if I use a LongWikiWord it opens > WikiWord.txt instead of LongWikiWord.txt. It depends on where I click > on the word. If I click on Long nothing happens and if I click on Wiki > it opens WikiWord. > > Is this a problem of the rule or a "feature"? I use acme from Plan 9 > ports. i don't think your rule matches LongWikiWord because the rule will only match words with an even number of studly caps. assuming that you want >= 2 studly caps, i think the rule you'd rather is data matches '[A-Z]+[a-z]+([A-Z]+[a-z]+)+' - erik