Josiah,
I am busy at the moment but I am sure I can brainstorm some cases for
regex.
Does defining a macro containing the regex then using regexp<macro> resolve
the use of "[ ]"?
Off the top of my head
- The equal test (already)
- The Not equal test if there is one
- Searching for common tiddlywiki patterns `{{ }} {{!! << [[ ||` and
when they have matching braces extract what is between them
- Imagine if we could search for the use of templates
`{{something||template}}`
- Given a keyword find "keyword:" "[[keyword]]" etc...
- Find keyword pairs eg keyword="value" keyword:"value" keyword:value
need to account for ' "" """
- Search values and get values (less the keyword)
- Find the delimiters in use eg [[]] "," "/"
- Count the number of delimiters eg how many "/" in a title
Any thing which results in a numeric output will have more value than ever
with the introduction of maths operators.
Regards
Tony
On Friday, August 2, 2019 at 2:27:35 AM UTC+10, @TiddlyTweeter wrote:
>
> An issue in TW in filters with regex is that "[" "]" are needed too in
> regex for "character classes" (e.g. [a-f, A-G]) to get them to work
> requires a bit more than normal regex since you can't use square brackets
> directly in TW regex filters, otherwise its works as expected.
>
> A few things like that I can explain how to deal with.
>
> I'm now thinking about it as there seems to be interest.
>
> J.
>
>
> On Thursday, 1 August 2019 18:01:49 UTC+2, Mohammad wrote:
>>>
>>> Josiah,
>>> I would also appreciate if you could provide examples of common and
>>> useful pattern of regexp in TW!
>>> You favored me and provided a help page for SnR in Tiddler Commander!
>>>
>>> I know regexp is very powerful but in tiddlywiki.com there is little
>>> documentation on that!
>>>
>>> You can have a daily post like *An Example a Day Using regexp with
>>> Tiddlywiki* :-)
>>>
>>> Cheers
>>> Mohammad
>>>
>>>
>>>
>>> On Thursday, August 1, 2019 at 7:41:53 PM UTC+4:30, @TiddlyTweeter wrote:
>>>>
>>>> TonyM wrote:
>>>>>
>>>>>
>>>>> I would not underestimate the value of a plain English operator like
>>>>> match for easy to read tests especially when they control visibility and
>>>>> structure in code.
>>>>>
>>>>
>>>> Don't disagree. But its not a straw man. Its the intelligent man--when
>>>> you need her. Your example triumphed plain English *ignoring regex
>>>> does plain already*.
>>>>
>>>>
>>>>> On regex you could give the community A great resource if you provide
>>>>> 10 to 20 top regex tests we may want to use. I could brainstorm some
>>>>> desirable ones.
>>>>>
>>>>
>>>> I'd happily do it. But I need to know what is needed. What is relevant?
>>>>
>>>> TT
>>>>
>>>>>
--
You received this message because you are subscribed to the Google Groups
"TiddlyWiki" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
To view this discussion on the web visit
https://groups.google.com/d/msgid/tiddlywiki/b4a13c09-492b-4b1c-b4ab-3245551ff6f4%40googlegroups.com.