[tw5] Re: Compare two variables for equality and inequality

2018-11-07 Thread TonyM
Eric,

That is really cool, this simpler use of the reveal, This surely deserves 
being included in examples on TiddlyWiki.com?

Thanks
Tony


On Thursday, November 8, 2018 at 4:02:56 AM UTC+11, Eric Shulman wrote:
>
> On Tuesday, November 6, 2018 at 4:03:09 PM UTC-8, TonyM wrote:
>>
>> I am trying to make a simply comparison between two variables or one 
>> variable and a fields content.
>> eg; <> and  {{!!wiki-owner}}
>> or <> and  <>
>> I simply want a simple test or filter that will be true if they are the 
>> same 
>> and that will be false if they are the same 
>>
>
> Although it might not be obvious, the $reveal widget can do this very 
> easily.  Normally, the $reveal widget is used to compare a "text" value 
> with a value stored in the text field of a specified "state" tiddler, like 
> this:
>
> <$reveal type="match" state="$:/state/SampleReveal1" text="show">
>   show this if state tiddler content matches text param
> 
>
>
> However, there is an alternative syntax that allows comparisons between 
> any two values: while the "state" param can only use an implied reference 
> to the "text" field of a specified tiddler, the "default" param can use ANY 
> literal, field or variable reference.  Simply OMIT the "state" param and 
> use the "default" param in it's place, like this:
>
> <$reveal type="match" default={{somefield!!sometiddler}} text="show">
>show this if some field in some tiddler matches text param
> 
>
> or
>
> <$reveal type="match" default=<> text="show">
>show this if somevariable matches text param
> 
>
>
> and... since the "text" param also can use ANY field or variable 
> reference, you can use <$reveal> to compare any two variables, like this:
>
> <$reveal type="match" default=<> text=<>>
>show this if somevariable value matches someOtherVariable
> 
>
>
> and... you can use any of the valid "type" values to make the comparison, 
> including the recently added LT, GT, LTEQ and GTEQ types.
>
> For example, if you have some "task tiddlers" tagged with "todo" OR 
> "done", you could display conditional output this way:
>
> <$set name="todo" filter="[tag[todo]count[]]">
> <$set name="done" filter="[tag[done]count[]]">
> <$reveal type="match"   default=<> text="0"> There is nothing to 
> do. 
> <$reveal type="nomatch" default=<> text="0">
><$reveal type="match" default=<> text="0">  You haven't 
> started. 
><$reveal type="LT"default=<> text=<>> You're making 
> progress... keep going!
><$reveal type="match" default=<> text=<>> You're half way 
> there... take a short break  
><$reveal type="GT"default=<> text=<>> You've done a 
> lot... but there's still some left 
> 
> 
> 
>
> Hope this helps.
>
> enjoy,
> -e
> Eric Shulman
> TiddlyTools.com: "Small Tools for Big Ideas!" (tm)
> InsideTiddlyWiki: The Missing Manuals
>

-- 
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 tiddlywiki+unsubscr...@googlegroups.com.
To post to this group, send email to tiddlywiki@googlegroups.com.
Visit this group at https://groups.google.com/group/tiddlywiki.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/tiddlywiki/48cdcbea-223b-4df7-a62c-354306b1db1f%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: [tw5] PHP 5.6 EOL on December 31, what does this mean for the PHP saver?

2018-11-07 Thread TonyM
Quaraman,

Not withstanding your concerns, I still see value in being able to read and 
write using PHP independently of TiddlyWikis save steps. Remember such a 
website can be restricted to a single user with SSL and multiple levels of 
authentication, then all that would be permitted it to write to a 
particular filename, perhaps even one only the server can see. We could use 
the security method in https://github.com/sendwheel/tw-receiver which stops 
update access unless you have a long password/phrase set.

I am not asking for a PHP lesson, only some insight as to how easy and or 
versatile this would be, and how you may invoke PHP from inside a 
TiddlyWiki. If accessible I will go to the effort of learning more about 
PHP.

Thanks in advance
Tony



On Tuesday, 30 October 2018 23:27:02 UTC+11, Sven Wetzel wrote:
>
> Hi Tony,
>
> this is to unspecific to answer the questions.
>
> What is your concrete case? 
>
> This type of extension is easy to program - only to save a file. But as I 
> described earlier : the difficult part is to decide how to handle the 
> rights and/or the security and/or your need to proove against such things 
> as illegal data (malware/copyrighted material/files that are only for 
> adults...)
>
> Regards,
> quaraman
>
>
> TonyM > schrieb am Di., 30. Okt. 2018, 
> 10:15:
>
>> Sven,
>>
>> If the functions exposed were limited like can only save to a specific 
>> filename etc could we make it safer?
>>
>> If however this wiki would be behind a password and only trusted users 
>> had access, how far could we take this and would it be difficult?.
>>
>> I would appreciate your advice.
>>
>> Regards
>> Tony
>>
>> -- 
>> 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 tiddlywiki+...@googlegroups.com .
>> To post to this group, send email to tiddl...@googlegroups.com 
>> .
>> Visit this group at https://groups.google.com/group/tiddlywiki.
>> To view this discussion on the web visit 
>> https://groups.google.com/d/msgid/tiddlywiki/fc7ac71f-df91-4096-b74b-bd42ec56727e%40googlegroups.com
>> .
>> For more options, visit https://groups.google.com/d/optout.
>>
>

-- 
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 tiddlywiki+unsubscr...@googlegroups.com.
To post to this group, send email to tiddlywiki@googlegroups.com.
Visit this group at https://groups.google.com/group/tiddlywiki.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/tiddlywiki/51ea6c79-ea1a-48cb-9261-24d88dc9f77c%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: [tw5] Re: Compare two variables for equality and inequality

2018-11-07 Thread TonyM
Jeremy,

When you say


You should only use <> to render a global macro if you want the 
content of the macro to be wikified. If you don’t, then you should use the 
<$text> or <$view> widgets. 

This confuses me, because I made a global variable/macro called currentWiki to 
pull a value from a data tiddler for the current wiki name. I dont want to fuss 
with the details just use the result globaly.

I want to use this "macro" where ever I need it, in a filter, in text, as a 
link to a tiddller of that name etc..  Should I have used the text widget in 
the currentWiki macro so the result is the same if wikified or not?

When I understand, I will explain the best practice idea 

Regards
Tony


-- 
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 tiddlywiki+unsubscr...@googlegroups.com.
To post to this group, send email to tiddlywiki@googlegroups.com.
Visit this group at https://groups.google.com/group/tiddlywiki.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/tiddlywiki/a4f16a66-de89-4a0a-877a-71788b2d1651%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[tw5] Re: field math: field = field + 1

2018-11-07 Thread Dave
Found it!

this works
<>

I had skipped that previously because I though "by" indicated something 
else, but it actually is:

a value or a TextReference  serving 
> as the operand if the *operation* does not define any
>

-- 
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 tiddlywiki+unsubscr...@googlegroups.com.
To post to this group, send email to tiddlywiki@googlegroups.com.
Visit this group at https://groups.google.com/group/tiddlywiki.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/tiddlywiki/5f1aeab6-bb90-40f6-9d0b-4172c4c61fdf%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: [tw5] Re: Compare two variables for equality and inequality

2018-11-07 Thread TonyM
Jeremy,

Interesting, I have never heard it put this way. 


You should only use <> to render a global macro if you want the 
content of the macro to be wikified.

I need to think about that. If a variable in the list widget, wikify or set 
widget is used they will also be wikified <>?

If you look back to my example I solved the problem by using wikify, which 
seems to contradict the above. I am sure I am missing a subtle detail.

Thank
Tony

-- 
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 tiddlywiki+unsubscr...@googlegroups.com.
To post to this group, send email to tiddlywiki@googlegroups.com.
Visit this group at https://groups.google.com/group/tiddlywiki.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/tiddlywiki/183b254e-69d2-4d23-a360-53c32e208573%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[tw5] Re: field math: field = field + 1

2018-11-07 Thread TonyM
Dave,

I think you must use a text reference {{!!fieldname}} or fieldname

But never a !!fieldname

Check the calc doc and look for an example.

Tony

-- 
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 tiddlywiki+unsubscr...@googlegroups.com.
To post to this group, send email to tiddlywiki@googlegroups.com.
Visit this group at https://groups.google.com/group/tiddlywiki.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/tiddlywiki/0c600032-6701-4e57-b85b-2dc40524ea30%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[tw5] Re: Wiki file disappearing with Firefox

2018-11-07 Thread TonyM
Yes snapshots
Retained until deleted or n versions cycle option.

Great stuff mario, as usual.

Tony

-- 
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 tiddlywiki+unsubscr...@googlegroups.com.
To post to this group, send email to tiddlywiki@googlegroups.com.
Visit this group at https://groups.google.com/group/tiddlywiki.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/tiddlywiki/1db3fd2e-68b7-46bf-baec-ab26fb9720ec%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: [tw5] Re: edit-text-operation for Linkmanager in a Storyeditor

2018-11-07 Thread Jan

Hi Tony,
this seems to be a very smart solution.
I have to wait for the weekend to check out..

Thanks a lot Jan

Am 07.11.2018 um 01:57 schrieb TonyM:

Post Script

To stop duplicate tiddlers in the first place, if the wikis that users 
were adding to had a new Edit Button, that only showed when it was a 
tiddler for which they were the creator that may help. Then refuse to 
import any tiddler that will overwrite and existing one (using the 
bundler plugin), tell the users you will not accept edits to existing 
tiddlers.


Regards
Tony

On Wednesday, November 7, 2018 at 11:39:02 AM UTC+11, TonyM wrote:

Jan,

I have worked on the principals behind doing this, as a result of
discussions arising from the New Comments plugin in 5.1.18 and my
desire to publish noteself Wikis online from which people can
export and send any tiddlers they modify or create for subsequent
inclusion in another Wiki.

A Quick work around, is to install Marios bundle
https://wikilabs.github.io/editions/bundler/#%24%3A%2FControlPanel

that has a setting to allow you to stop overwrites during import.

Personally I think the best approach is to build an new import
feature. The $:/import tiddler is created from
$:/core/ui/ImportListing Each time an import takes place.

I have added a list to add additional columns to the import table

|
<$list filter="[tag[$:/tags/importcolumn]]"
variable=import-column-tiddler> <$transclude
tiddler=<> field="text"/> 
|

This is not at all complete, but I would like to add the ability to add a 
prefix during import.

I would suggest in your case the tiddlers are prefixed something like 
$:/importfrom/modifier/"original tiddler name"

Then it would be a simple matter of adding to the view template, the 
ability to list below any given tiddler, a list of tiddlers who's suffix is the 
same as the current tiddler name

eg; "original tiddler name" From there you can decide how you will treat 
each one.

Of course we could make this even more sophisticated to facilitate your 
needs, ie accepting collaborative input, but I believe this lies with the 
import facility.

I hope to add a feature to the import, not to import tiddlers that have a wiki-owner 
field set to the current wiki, to stop over-writing the tiddlers "source of 
truth".

Regards

Tony



On Wednesday, November 7, 2018 at 10:24:19 AM UTC+11, Jan wrote:

Hi Tony
the problem I want to solve by creating tiddlernames including
the modifier is that this would prevent overwriting tiddlers.
When my students write stories there is a strong probability
that some have a tiddlers with matching names [[In the
morning]] or [[later]]
Importing both would ruin one of the stories.

Yours Jan


Am 06.11.2018 um 22:51 schrieb TonyM:

Jan,

If the $:/status/UserName is set, it will populate hidden
fields in each tiddler called creator and/or modifier see
https://tiddlywiki.com/#TiddlerFields


  * You could then use normal filter operators to select the
different users tiddlers via these fields
  * You could set these field manually in
tiddlers <$edit-text tiddler=tiddlername
field="modifier"/> (From another tiddler - not the
current) or by other using a template.

With the above information, I wonder if your question is
still relevant?

Regards
Tony

On Tuesday, November 6, 2018 at 8:37:23 AM UTC+11, Jan wrote:

|Dear Writers

Is there something like
<$action-sendmessage $message="tm-edit-text-operation" 
$param="write-selection-to"||title/>

I want to use Tiddlywiki to write nonlinear stories with a group of 
students. To import and mix stories it is necessary to add the usernames to the 
Tiddlers created.
This is why I would like to automatically set a Link of this 
structure [[selection{{$:/status/UserName}}/selection]]


I tried this...but it always has a delay of one click...

|  
\define Userlink()

[[{{$:/Temp/newlink}}|{{$:/status/UserName}}/{{$:/Temp/newlink}}]]
\end

<$action-sendmessage
$message="tm-edit-text-operation"
$param="excise"
title="$:/Temp/newlink"
type="link"
/>
<$wikify name="Newlink" text=<>>
<$action-sendmessage $message="tm-edit-text-operation" $param="replace-selection"  
text=<> />


Is there a solution for this Problem?

Greetings Jan

|

-- 
You received this message because you are subscribed to the


[tw5] Re: Problems connecting to my tiddlywiki on my Android phone installed with nodejs (Termux) using a different device on my local network

2018-11-07 Thread john smith
Lazy loading is working well so far, thank you very much!

On Wednesday, November 7, 2018 at 12:33:47 AM UTC, Mark S. wrote:
>
>
> TW isn't indexed like a database and doesn't scale up well. I try to keep 
> it below 10M for compatibility with devices. 30-40 Megs is the upper range 
> on my desk-top machine.
>
> The solution is to put images, PDF's, etc. into sub-directories. 
> Unfortunately plain node.js won't serve up images, etc. I don't know if 
> anyone has tried tiddlyserver on a device, but TS will serve up images and 
> PDF's (though whether your device browser can use the PDF is another 
> question).
>
> Another possibility on node.js is to use "lazy loading". This brings in 
> all regular tiddlers as empty until you click on them. This can greatly 
> reduce the memory load since it's unlikely that you need to look at all the 
> content all the time.
>
> Good luck
> -- Mark
>
> On Tuesday, November 6, 2018 at 3:05:58 PM UTC-8, john smith wrote:
>>
>> Thanks guys i got it working.
>>
>> My next issue is that i've imported a very large static html tiddlywiki 
>> (over 200mb, full of images, PDF's, saved webpages etc) into the nodejs 
>> version, after successfully importing it runs out of memory when i try and 
>> load it in the browser. Below is a screenshot out of the Termux output.
>>
>>
>>
>> On Tuesday, November 6, 2018 at 5:35:44 PM UTC, Mark S. wrote:
>>
>>> How are you launching node.js/TiddlyWiki ? You need to specify the full 
>>> IP number in order to open it to the network. Something like:
>>>
>>> --server 8080 $:/core/save/all text/plain text/html "" "" 192.168.0.245
>>>
>>> where 192.168.0.245 is the IP of your "server" device.
>>>
>>> Good luck!
>>> -- Mark
>>>
>>>
>>> On Tuesday, November 6, 2018 at 8:22:23 AM UTC-8, john smith wrote:

 So i've installed tiddlywiki via nodejs on my Android phone using Termux

 Runs well on my phone browser when connecting to http://127.0.0.1:8080/

 However I can't see the tiddlywiki on any other device on the local 
 network (my laptop and ipad).

 I'm using the local IP address provided on the android wi-fi settings 
 and the port (192.168.x.x:8080) in browser.

 i'm not very technically minded so hopefully the solution doesn't 
 involve too much hassle every time i'm connected to a different wi-fi as i 
 travel a lot.

>>>

-- 
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 tiddlywiki+unsubscr...@googlegroups.com.
To post to this group, send email to tiddlywiki@googlegroups.com.
Visit this group at https://groups.google.com/group/tiddlywiki.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/tiddlywiki/549f819b-7109-4ebf-97e3-586d478d699f%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[tw5] Re: iOS Chrome Javascript Error

2018-11-07 Thread 'Mark S.' via TiddlyWiki
Are you getting the Red-Screen-of-Embarassment error, or some other kind of 
error?

I'm not on a machine with Chrome at the minute, but I believe you can open 
a Javascript Console from the tool bar. This should allow you to see errors 
that are being generated and possibly report them here.

Also, back at your Windows machine, there should be some kind of activity 
reported whenever you attempt to save. That information could be useful in 
diagnosing your situation.

Good luck
-- Mark


On Wednesday, November 7, 2018 at 11:03:31 AM UTC-8, Appeal System wrote:
>
> Hey all,
>
> I am running into an issue where when I attempt to edit the text for a 
> tiddler using iOS chrome I get an internal Javascript Error: Script Error. 
>
> Everything works fine on Safari iOS, and works fine in Chrome Browser in 
> Windows. 
>
> Running TW5 in a NodeJS from a Windows 10 machine. 
>
>
> *Things I've tried:*
>
> - Delete iOS Chrome and Reinstall
> - Download a clean install of TW5 node JS, empty and get the same error. 
>
> Does anyone else get this error or is it just me?
>
> Is this a setting in iOS Chrome that is blocking Javascript?
>
> Currently using iOS 12.1 (not that I think that matters).
>
>
> Are there any other steps I can take?
>
> Can I npm global delete tiddlywiki without my wiki folders getting deleted?
>
> Thanks for your help.
>
>
>
>
>
>
>
>

-- 
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 tiddlywiki+unsubscr...@googlegroups.com.
To post to this group, send email to tiddlywiki@googlegroups.com.
Visit this group at https://groups.google.com/group/tiddlywiki.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/tiddlywiki/63c2d79a-850f-4c1f-b40d-dfcc199c0709%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[tw5] Re: 2017 was? 2018 hopes?

2018-11-07 Thread Mohammad
Yes, please do it!
This way we can find what important and useful stuff are introduced this 
year and this is kind of notification/advertisement!

Best
Mohammad

-- 
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 tiddlywiki+unsubscr...@googlegroups.com.
To post to this group, send email to tiddlywiki@googlegroups.com.
Visit this group at https://groups.google.com/group/tiddlywiki.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/tiddlywiki/9296a456-8a91-4f76-bb88-0349d3586285%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[tw5] Re: 2017 was? 2018 hopes?

2018-11-07 Thread @TiddlyTweeter
Ciao Mohammad. You ask it this year, ok?

I suggest that December 31st is probably the best day to ask it :-)

Josiah, x

On Tuesday, 6 November 2018 21:17:11 UTC+1, Mohammad wrote:
>
> Hi Josiah,
>  Don't want to ask this question for 2018? I think it is a good question 
> to be raised for Dec 2018!
>
> -Mohammad
>

-- 
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 tiddlywiki+unsubscr...@googlegroups.com.
To post to this group, send email to tiddlywiki@googlegroups.com.
Visit this group at https://groups.google.com/group/tiddlywiki.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/tiddlywiki/6eb02852-e280-4732-a64c-5ac71ef2cff9%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[tw5] Re: Compare two variables for equality and inequality

2018-11-07 Thread Mohammad
Thank you Eric! great explanation!

Thank you Thomas for such great collection of TW codes!

Mark, I totally agree with you! I am actually learning TW in this forum!
It is very hard or impossible to learn such features from tiddlywiki.com!

- Mohammad

-- 
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 tiddlywiki+unsubscr...@googlegroups.com.
To post to this group, send email to tiddlywiki@googlegroups.com.
Visit this group at https://groups.google.com/group/tiddlywiki.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/tiddlywiki/95c0378b-4f4c-44aa-ba8b-ec7cbda7986b%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[tw5] iOS Chrome Javascript Error

2018-11-07 Thread Appeal System
Hey all,

I am running into an issue where when I attempt to edit the text for a 
tiddler using iOS chrome I get an internal Javascript Error: Script Error. 

Everything works fine on Safari iOS, and works fine in Chrome Browser in 
Windows. 

Running TW5 in a NodeJS from a Windows 10 machine. 


*Things I've tried:*

- Delete iOS Chrome and Reinstall
- Download a clean install of TW5 node JS, empty and get the same error. 

Does anyone else get this error or is it just me?

Is this a setting in iOS Chrome that is blocking Javascript?

Currently using iOS 12.1 (not that I think that matters).


Are there any other steps I can take?

Can I npm global delete tiddlywiki without my wiki folders getting deleted?

Thanks for your help.







-- 
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 tiddlywiki+unsubscr...@googlegroups.com.
To post to this group, send email to tiddlywiki@googlegroups.com.
Visit this group at https://groups.google.com/group/tiddlywiki.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/tiddlywiki/29eabbe7-4a74-4eaa-88ef-5bb69d1360a8%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[tw5] Re: some new tiddlers in Bob disappearing

2018-11-07 Thread 'Mark S.' via TiddlyWiki
I'm still wondering if Syncthing and Bob got into a tussle, and a tiddler 
in an indeterminate state was a casualty.

-- Mark

On Wednesday, November 7, 2018 at 10:16:07 AM UTC-8, Dave wrote:
>
> Yes I still get the error when I pause all folders in Syncthing, and now 
> I've just killed the syncthing process and it still happens
>
> I just tested it with the content "asdf" and even that didn't stick, so 
> its not about the "code" after all.
>
> The tiddler name is just "variables in TW5" 
>
> if I rename it to "variables in TW5 Part 2" 
> it saves just fine... O_o
>
> its like Bob just occasionally decides he doesn't like a certain title...
>
> so weird
>
>
> I found a file in the tiddlers folder called "variables in TW5.tid.meta", 
> so I deleted it and now creating a new tiddler named "variables in TW5" 
> saves just fine
>
> it had this in it:
>
>> created: 20181107024644431
>>
>> modified: 20181107154310520
>>
>> tags: 
>>
>> title: variables in TW5
>>
>> type: text/vnd.tiddlywiki
>>
>>
> now that it works the tid file is there but the meta file is not
>
>

-- 
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 tiddlywiki+unsubscr...@googlegroups.com.
To post to this group, send email to tiddlywiki@googlegroups.com.
Visit this group at https://groups.google.com/group/tiddlywiki.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/tiddlywiki/166c5a8b-09ae-491f-8f9b-acedcba4df53%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[tw5] Re: some new tiddlers in Bob disappearing

2018-11-07 Thread Dave
Yes I still get the error when I pause all folders in Syncthing, and now 
I've just killed the syncthing process and it still happens

I just tested it with the content "asdf" and even that didn't stick, so its 
not about the "code" after all.

The tiddler name is just "variables in TW5" 

if I rename it to "variables in TW5 Part 2" 
it saves just fine... O_o

its like Bob just occasionally decides he doesn't like a certain title...

so weird


I found a file in the tiddlers folder called "variables in TW5.tid.meta", 
so I deleted it and now creating a new tiddler named "variables in TW5" 
saves just fine

it had this in it:

> created: 20181107024644431
>
> modified: 20181107154310520
>
> tags: 
>
> title: variables in TW5
>
> type: text/vnd.tiddlywiki
>
>
now that it works the tid file is there but the meta file is not

-- 
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 tiddlywiki+unsubscr...@googlegroups.com.
To post to this group, send email to tiddlywiki@googlegroups.com.
Visit this group at https://groups.google.com/group/tiddlywiki.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/tiddlywiki/0f0714d7-1270-4312-8b57-4c6269c83e6f%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[tw5] Re: Compare two variables for equality and inequality

2018-11-07 Thread 'Mark S.' via TiddlyWiki
This is great to know, but really, really understated in the documentation. 
I'm thinking that there should be at least a line or two in the 
RevealWidget documentation, and maybe an example, that advertises this 
ability. Especially since the RevealWidget, unlike filter syntax, now has a 
bunch of comparison operators.

Thanks!
-- Mark



On Wednesday, November 7, 2018 at 9:02:56 AM UTC-8, Eric Shulman wrote:
>
> On Tuesday, November 6, 2018 at 4:03:09 PM UTC-8, TonyM wrote:
>>
>> I am trying to make a simply comparison between two variables or one 
>> variable and a fields content.
>> eg; <> and  {{!!wiki-owner}}
>> or <> and  <>
>> I simply want a simple test or filter that will be true if they are the 
>> same 
>> and that will be false if they are the same 
>>
>
> Although it might not be obvious, the $reveal widget can do this very 
> easily.  Normally, the $reveal widget is used to compare a "text" value 
> with a value stored in the text field of a specified "state" tiddler, like 
> this:
>
> <$reveal type="match" state="$:/state/SampleReveal1" text="show">
>   show this if state tiddler content matches text param
> 
>
>
> However, there is an alternative syntax that allows comparisons between 
> any two values: while the "state" param can only use an implied reference 
> to the "text" field of a specified tiddler, the "default" param can use ANY 
> literal, field or variable reference.  Simply OMIT the "state" param and 
> use the "default" param in it's place, like this:
>
> <$reveal type="match" default={{somefield!!sometiddler}} text="show">
>show this if some field in some tiddler matches text param
> 
>
> or
>
> <$reveal type="match" default=<> text="show">
>show this if somevariable matches text param
> 
>
>
> and... since the "text" param also can use ANY field or variable 
> reference, you can use <$reveal> to compare any two variables, like this:
>
> <$reveal type="match" default=<> text=<>>
>show this if somevariable value matches someOtherVariable
> 
>
>
> and... you can use any of the valid "type" values to make the comparison, 
> including the recently added LT, GT, LTEQ and GTEQ types.
>
> For example, if you have some "task tiddlers" tagged with "todo" OR 
> "done", you could display conditional output this way:
>
> <$set name="todo" filter="[tag[todo]count[]]">
> <$set name="done" filter="[tag[done]count[]]">
> <$reveal type="match"   default=<> text="0"> There is nothing to 
> do. 
> <$reveal type="nomatch" default=<> text="0">
><$reveal type="match" default=<> text="0">  You haven't 
> started. 
><$reveal type="LT"default=<> text=<>> You're making 
> progress... keep going!
><$reveal type="match" default=<> text=<>> You're half way 
> there... take a short break  
><$reveal type="GT"default=<> text=<>> You've done a 
> lot... but there's still some left 
> 
> 
> 
>
> Hope this helps.
>
> enjoy,
> -e
> Eric Shulman
> TiddlyTools.com: "Small Tools for Big Ideas!" (tm)
> InsideTiddlyWiki: The Missing Manuals
>

-- 
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 tiddlywiki+unsubscr...@googlegroups.com.
To post to this group, send email to tiddlywiki@googlegroups.com.
Visit this group at https://groups.google.com/group/tiddlywiki.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/tiddlywiki/a6446511-a340-4643-9fcd-2066051a8f9f%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[tw5] Re: field math: field = field + 1

2018-11-07 Thread Dave
Okay, I'm trying to subtract one field from another

field "due" is 20181112

and field "mynow" is 20181106

this works:
<>
to give 2018

but I've tried this
<>
and this
<>
and this
< >>

and I either get "20181112" as the result, or NaN 


Is the calc macro only able to calculate with a single field?


-- 
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 tiddlywiki+unsubscr...@googlegroups.com.
To post to this group, send email to tiddlywiki@googlegroups.com.
Visit this group at https://groups.google.com/group/tiddlywiki.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/tiddlywiki/fd93806d-f777-4dce-baec-e79453673775%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[tw5] Re: some new tiddlers in Bob disappearing

2018-11-07 Thread 'Mark S.' via TiddlyWiki
I'm not able to replicate on my Linux Bob. 

What tiddler name are you using?

I notice at the very bottom you say "synchthing" Are you using the 
synchthing software? If you turn it off, does the problem persist?

Good luck!
-- Mark

On Wednesday, November 7, 2018 at 8:04:04 AM UTC-8, Dave wrote:
>
> Good Morning,
>
> I have a BobWiki instance running, and there's sometimes when I paste in 
> some information, e.g. with code in it, whereby the tiddler briefly renders 
> after a save tiddler, but then it disappears
>
> Here's an example of something I tried pasting in which triggered that 
> error:
>
> variables in TW5
>>
>>
>>>
>>> You can also use *variables* to "pass" named parameters for the 
>>> transclusion, like this:
>>
>><$vars foo="mumble" bar="frotz">
>>
>>{{||TiddlerB}}
>>
>>
>>
>> where TiddlerB contains something like:
>>
>>This is from {{!!title}}
>>
>>The value of foo = <>
>>
>>The value of bar = <>
>>
>>
>>> Thus, in TWC you write:
>>
>><>
>>
>> while in modern TW you write:
>>
>><$vars var1="arg1" var2="arg2" var3="arg3" ...>
>>
>>{{NameOfTiddler}}
>>
>>
>>
>>
>>>
>>> https://groups.google.com/forum/#!searchin/tiddlywiki/data$20tiddler$20examples$20tw5|sort:date/tiddlywiki/XHvrJQVUqYs/eUJ29h2nAgAJ
>>
>>
> I've tried putting ``` with carriage returns in front and after to bracket 
> this content and it still doesn't stay.  I did paste this into a regular 
> TW5 and it stayed just fine.
>
> I've also noticed tiddlers disappearing (less frequently) that were more 
> "normal", but I had thought I had screwed up my syncthing syncing, but now 
> I'm wondering if its the same problem...  For that I had started 
> immediately clicking the save icon, but I'm not sure if that was really 
> helping or not.
>

-- 
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 tiddlywiki+unsubscr...@googlegroups.com.
To post to this group, send email to tiddlywiki@googlegroups.com.
Visit this group at https://groups.google.com/group/tiddlywiki.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/tiddlywiki/d4a733d5-ca1a-4c62-bdbc-0e0708e49718%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[tw5] Re: Compare two variables for equality and inequality

2018-11-07 Thread Thomas Elmiger
Maybe too late, but I documented a hack for this about 13 months ago:

https://tid.li/tw5/hacks.html#ifAisB%20%E2%80%93%20Compare%20if-then-else%20Style%20in%20Wikitext

All the best, 
Thomas 

-- 
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 tiddlywiki+unsubscr...@googlegroups.com.
To post to this group, send email to tiddlywiki@googlegroups.com.
Visit this group at https://groups.google.com/group/tiddlywiki.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/tiddlywiki/93c45a4b-0385-4910-92f3-e2eb3358559f%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[tw5] Re: Compare two variables for equality and inequality

2018-11-07 Thread Eric Shulman
On Tuesday, November 6, 2018 at 4:03:09 PM UTC-8, TonyM wrote:
>
> I am trying to make a simply comparison between two variables or one 
> variable and a fields content.
> eg; <> and  {{!!wiki-owner}}
> or <> and  <>
> I simply want a simple test or filter that will be true if they are the 
> same 
> and that will be false if they are the same 
>

Although it might not be obvious, the $reveal widget can do this very 
easily.  Normally, the $reveal widget is used to compare a "text" value 
with a value stored in the text field of a specified "state" tiddler, like 
this:

<$reveal type="match" state="$:/state/SampleReveal1" text="show">
  show this if state tiddler content matches text param



However, there is an alternative syntax that allows comparisons between any 
two values: while the "state" param can only use an implied reference to 
the "text" field of a specified tiddler, the "default" param can use ANY 
literla, field or variable reference.  Simply OMIT the "state" param and 
use the "default" param in it's place, like this:

<$reveal type="match" default={{somefield!!sometiddler}} text="show">
   show this if somevariable value matches text param


or

<$reveal type="match" default=<> text="show">
   show this if somevariable value matches text param



and... since the "text" param also can use ANY field or variable reference, 
you can use <$reveal> to compare any two variables, like this:

<$reveal type="match" default=<> text=<>>
   show this if somevariable value matches text param



and... you can use any of the valid "type" values to make the comparison, 
including the recently added LT, GT, LTEQ and GTEQ types.

For example:

<$set name="todo" filter="[tag[todo]count[]]">
<$set name="done" filter="[tag[done]count[]]">
<$reveal type="match"   default=<> text="0"> There is nothing to do. 

<$reveal type="nomatch" default=<> text="0">
   <$reveal type="match" default=<> text="0">  You haven't 
started. 
   <$reveal type="LT"default=<> text=<>> You're making 
progress... keep going!
   <$reveal type="match" default=<> text=<>> You're half way 
there... take a short break  
   <$reveal type="GT"default=<> text=<>> You've done a 
lot... but there's still some left 




Hope this helps.

enjoy,
-e
Eric Shulman
TiddlyTools.com: "Small Tools for Big Ideas!" (tm)
InsideTiddlyWiki: The Missing Manuals

-- 
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 tiddlywiki+unsubscr...@googlegroups.com.
To post to this group, send email to tiddlywiki@googlegroups.com.
Visit this group at https://groups.google.com/group/tiddlywiki.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/tiddlywiki/9fefb7ad-af42-4361-84a9-6efb3ec5abef%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[tw5] Re: Conditional Output

2018-11-07 Thread Mohammad
Hello Mario,
 many thanks for clarification.

Best
Mohammad

-- 
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 tiddlywiki+unsubscr...@googlegroups.com.
To post to this group, send email to tiddlywiki@googlegroups.com.
Visit this group at https://groups.google.com/group/tiddlywiki.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/tiddlywiki/042b627e-6357-435e-b330-4d9665bce18e%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[tw5] some new tiddlers in Bob disappearing

2018-11-07 Thread Dave
Good Morning,

I have a BobWiki instance running, and there's sometimes when I paste in 
some information, e.g. with code in it, whereby the tiddler briefly renders 
after a save tiddler, but then it disappears

Here's an example of something I tried pasting in which triggered that 
error:

variables in TW5
>
>
>>
>> You can also use *variables* to "pass" named parameters for the 
>> transclusion, like this:
>
><$vars foo="mumble" bar="frotz">
>
>{{||TiddlerB}}
>
>
>
> where TiddlerB contains something like:
>
>This is from {{!!title}}
>
>The value of foo = <>
>
>The value of bar = <>
>
>
>> Thus, in TWC you write:
>
><>
>
> while in modern TW you write:
>
><$vars var1="arg1" var2="arg2" var3="arg3" ...>
>
>{{NameOfTiddler}}
>
>
>
>
>>
>> https://groups.google.com/forum/#!searchin/tiddlywiki/data$20tiddler$20examples$20tw5|sort:date/tiddlywiki/XHvrJQVUqYs/eUJ29h2nAgAJ
>
>
I've tried putting ``` with carriage returns in front and after to bracket 
this content and it still doesn't stay.  I did paste this into a regular 
TW5 and it stayed just fine.

I've also noticed tiddlers disappearing (less frequently) that were more 
"normal", but I had thought I had screwed up my syncthing syncing, but now 
I'm wondering if its the same problem...  For that I had started 
immediately clicking the save icon, but I'm not sure if that was really 
helping or not.

-- 
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 tiddlywiki+unsubscr...@googlegroups.com.
To post to this group, send email to tiddlywiki@googlegroups.com.
Visit this group at https://groups.google.com/group/tiddlywiki.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/tiddlywiki/35c5129e-96aa-48c0-9602-752251281454%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[tw5] Re: Conditional Output

2018-11-07 Thread PMario
On Wednesday, November 7, 2018 at 1:10:26 PM UTC+1, Mohammad wrote:

Which other widget behave the same?
>

As you found out the "transclude" widget has the same behaviour. As far as 
I know, that are the only 2 widgets that work that way. .. At least the 
most important. 

Most of the time the "body" between start and end of the widget contains a 
template, that is used to render the content. 
 

> Is there any document on this?
>

see: https://tiddlywiki.com/#ViewWidget

> The content of the <$view> widget is displayed if the field or property 
is missing or empty.
^^

It seems the transclude widget has the same capability! 
>

yes
 

> Can we use these feature for making comparison and creating if-then-else 
> clause
>

.. Kind of. If your "if-clause" returns nothing. .. 

This behaviour is used all over the places in the TW UI. 

-mario

-- 
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 tiddlywiki+unsubscr...@googlegroups.com.
To post to this group, send email to tiddlywiki@googlegroups.com.
Visit this group at https://groups.google.com/group/tiddlywiki.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/tiddlywiki/04313469-8636-4d7d-91fa-466dabdebe96%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[tw5] Re: Wiki file disappearing with Firefox

2018-11-07 Thread @TiddlyTweeter
PMario wrote:

... from time to time it should be possible to create an "out of order" 
> snapshot. 
>

 Excellent idea! on SNAPSHOT! From my point of view I get I interested in 
internal TW backup when it gives "Added Value" above OS level backup... 
That really would!

Best wishes
Josiah

-- 
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 tiddlywiki+unsubscr...@googlegroups.com.
To post to this group, send email to tiddlywiki@googlegroups.com.
Visit this group at https://groups.google.com/group/tiddlywiki.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/tiddlywiki/ae3b003d-8d67-4641-b323-2c8cb39db4b2%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[tw5] Re: Wiki file disappearing with Firefox

2018-11-07 Thread PMario
On Wednesday, November 7, 2018 at 1:06:07 PM UTC+1, @TiddlyTweeter wrote:
 

> FYI, of all the INTERNAL backup systems TW has I find PMario's the best 
> from the point of view of VERSIONING. It uses an adaptation of the Towers 
> Of Hanoi system that makes great sense to get (1) good coverage (2) prevent 
> backup-itis when you get zillions of backups you don't need.
>

Thanks. ... That was the main reason, why I wanted to create it. (for 
myself ;) ... But I also think, from time to time it should be possible to 
create an "out of order" snapshot. eg. representing a milestone or 
something similar. 

The TW "save buttons" already support a filename parameter. I think it also 
should support a "snapshot" parameter. .. I'll have to test this a bit 
close.

have fun!
mario

-- 
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 tiddlywiki+unsubscr...@googlegroups.com.
To post to this group, send email to tiddlywiki@googlegroups.com.
Visit this group at https://groups.google.com/group/tiddlywiki.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/tiddlywiki/e7f5b661-cf40-4896-a645-03438d059104%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: [tw5] Re: Compare two variables for equality and inequality

2018-11-07 Thread Jeremy Ruston
Hi Tony

> 
> Can we establish a "best practice" approach such that when creating a macro 
> to return a value in the first place, say we use the text widget to create 
> "clean" value for use in filters to avoid this kind of issue. 

I’m not sure what issue? The issue here is that you were inadvertently 
wikifying a value; the fix is to not wikify it.

> In my use case, I retrieved a value from a data tiddler to set a variable 
> currentWiki, I made this a global macro so I could refer to <> 
> whenever I needed it. Perhaps I should have used the text widget to ensure 
> this value was already plain text.

You should only use <> to render a global macro if you want the 
content of the macro to be wikified. If you don’t, then you should use the 
<$text> or <$view> widgets.

> Alternativly could filters themself be improved to clean variables before 
> use, or would this have undesirable consequences?

What do you mean by “clean” variables?

Best wishes

Jeremy.


> 
> Regards
> Tony
> 
> -- 
> 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 tiddlywiki+unsubscr...@googlegroups.com.
> To post to this group, send email to tiddlywiki@googlegroups.com.
> Visit this group at https://groups.google.com/group/tiddlywiki.
> To view this discussion on the web visit 
> https://groups.google.com/d/msgid/tiddlywiki/0122167d-cd8b-4e71-b798-bf48b2041332%40googlegroups.com.
> For more options, visit https://groups.google.com/d/optout.

-- 
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 tiddlywiki+unsubscr...@googlegroups.com.
To post to this group, send email to tiddlywiki@googlegroups.com.
Visit this group at https://groups.google.com/group/tiddlywiki.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/tiddlywiki/D23003E5-45DA-49E7-94AC-915425E35804%40gmail.com.
For more options, visit https://groups.google.com/d/optout.


[tw5] Conditional Output

2018-11-07 Thread Mohammad
Eric Shulman in the below post showed the view widget has a conditional 
output, e.g in the below example the caption will be shown if it is existed 
and not Empty and title will be shown if there is no caption!


https://groups.google.com/d/msg/tiddlywiki/pNixD9nC_hQ/Cj94cGqrAQAJ

<$view field="caption">
   <$view field="title">




Which other widget behave the same? Is there any document on this?

It seems the transclude widget has the same capability! Can we use these 
feature for making comparison and creating if-then-else clause


-Mohammad

-- 
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 tiddlywiki+unsubscr...@googlegroups.com.
To post to this group, send email to tiddlywiki@googlegroups.com.
Visit this group at https://groups.google.com/group/tiddlywiki.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/tiddlywiki/cbd53193-87e6-473e-b4bb-d0d110907ee9%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[tw5] Re: Wiki file disappearing with Firefox

2018-11-07 Thread @TiddlyTweeter

I think its sensible to run EXTERNAL backup for TW. Its generally easy to 
do. 

Whatever internal save mechanisms I enable in TW (or not) I always have 
running a redundant system level backup that saves a dated copy whenever it 
detects change. Currently it runs every ten minutes using the Towers Of 
Hanoi system of versioning. 

In my experience TW is VERY robust, but is dependency on a browser always 
needs be taken into account.

FYI, of all the internal backup systems TW has I find PMario's the best 
from the point of view of VERSIONING. It uses an adaptation of the Towers 
Of Hanoi system that makes great sense to get (1) good coverage (2) prevent 
backup-itis when you get zillions of backups you don't need.

Best wishes
Josiah

-- 
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 tiddlywiki+unsubscr...@googlegroups.com.
To post to this group, send email to tiddlywiki@googlegroups.com.
Visit this group at https://groups.google.com/group/tiddlywiki.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/tiddlywiki/2b633424-af31-41fa-b5c7-4e4db52d69e0%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: [tw5] Re: Compare two variables for equality and inequality

2018-11-07 Thread TonyM
Jeremy,

Can we establish a "best practice" approach such that when creating a macro to 
return a value in the first place, say we use the text widget to create "clean" 
value for use in filters to avoid this kind of issue. 

In my use case, I retrieved a value from a data tiddler to set a variable 
currentWiki, I made this a global macro so I could refer to <> 
whenever I needed it. Perhaps I should have used the text widget to ensure this 
value was already plain text.

Alternativly could filters themself be improved to clean variables before use, 
or would this have undesirable consequences?

Regards
Tony

-- 
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 tiddlywiki+unsubscr...@googlegroups.com.
To post to this group, send email to tiddlywiki@googlegroups.com.
Visit this group at https://groups.google.com/group/tiddlywiki.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/tiddlywiki/0122167d-cd8b-4e71-b798-bf48b2041332%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[tw5] Re: Wiki file disappearing with Firefox

2018-11-07 Thread barrowgloom
In my instructions on the TW's I prepare for users, I have warnings about 
such things-- not just when FF tab or window being shut down, but even 
inadvertently leaving TW by following an external link in the wiki that 
isn't coded to open in a new tab or window; before saving which will cause 
any unsaved editing to be lost, especially in Private Browsing mode.  
Though I never lost the TW file on the hard drive.

I have left a TW open in FF over night many times without losing it-- 
though I don't know if any updates happened during those times.  My FF has 
auto updating, so I usually don't know when it updates.  Desktop machine 
hibernate is much different from laptop hibernate I believe.

I have completely lost the TW file on the hard drive a few times this 
summer during file saving.  No error messages, no crashes or freezes-- all 
the save prompts appeared and the save appeared to had worked and I closed 
the TW tab, shut the browser and computer down for the day.  Next day, the 
TW file is no where to be found and a deep data recovery scan of the hard 
drive turns up a file that's scrambled and useless after it's recovered.  I 
believe it was while saving in Private Browsing mode, which I don't use 
anymore for TW editing.

-- 
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 tiddlywiki+unsubscr...@googlegroups.com.
To post to this group, send email to tiddlywiki@googlegroups.com.
Visit this group at https://groups.google.com/group/tiddlywiki.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/tiddlywiki/ec780d5f-7355-4256-a92e-883bc7583ede%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: [tw5] Re: Compare two variables for equality and inequality

2018-11-07 Thread Jeremy Ruston
Hi Tony

> I believe it was not until I used wikify to create a variable 
> 
> The Following example does not work even although <> returns the 
> correct value
> 
> \define currentWiki() {{$:/PSaT/wikimanager/wiki-tiddler##wiki-title}}
> 
> <>

The double angle brackets syntax for rendering a macro/variable will wikify the 
text. So, for example, if the currentWiki variable contained `n//b//n` then you 
wouldn’t see the double slashes, you’d just see the “b” in italics.

Instead, you can use <$text text=<>/> which will just display the 
plain text of the variable/macro.


> 
> 
><$list filter="[] [{!!wiki-owner}] +[count[]] -[[2]]">
>same {{Certificate.svg}}
>
><$list filter="[] [{!!wiki-owner}] +[count[]] -[[1]]">
>different {{Certificate-not.svg}}
>
> 
> How ever when refactored this works
> 
> <$wikify name=this-wiki text="<>”>

The action of the wikify widget is to take the provided text and wikify it 
offscreen, and then extract the plain text content. So, in this case, the 
variable "this-wiki” will be set to textual result of wikifying the variable 
currentWiki. Again, if that variable happens to contain any wikitext markup 
then it will be processed, and only the resulting plain text will be returned.

To turn to the OP, a reasonable way to check whether a variable and a field or 
another variable are the same, try this:

<$edit-text tiddler="$:/temp/demo" field="foo"/>
<$set name="bar" value="Avocado">
<$list filter="[] -[{$:/temp/demo!!foo}]" emptyMessage="Same">
Different



Use the edit box to experiment with assigning different values to the “foo” 
field of the demo temp tiddler.

Best wishes

Jeremy.


><$list filter="[] [{!!wiki-owner}] +[count[]] -[[2]]">
>same {{Certificate.svg}}
>
><$list filter="[] [{!!wiki-owner}] +[count[]] -[[1]]">
>different {{Certificate-not.svg}}
>
> 
> 
> I stand to be corrected, but that is all I can say at this point.
> 
> Regards
> Tony
> 
> On Wednesday, November 7, 2018 at 5:03:21 PM UTC+11, Mohammad wrote:
> Hello Tony!
>  This is really interesting! I would appreciate if you could put it inside a 
> wiki and give link for future references!
> By the way you said the variables cannot be the result of a macro call, why?
> 
> -Mohammad
> 
> -- 
> 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 tiddlywiki+unsubscr...@googlegroups.com 
> .
> To post to this group, send email to tiddlywiki@googlegroups.com 
> .
> Visit this group at https://groups.google.com/group/tiddlywiki 
> .
> To view this discussion on the web visit 
> https://groups.google.com/d/msgid/tiddlywiki/962c78fe-6e3d-4860-a2c3-daeba7aeca98%40googlegroups.com
>  
> .
> For more options, visit https://groups.google.com/d/optout 
> .

-- 
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 tiddlywiki+unsubscr...@googlegroups.com.
To post to this group, send email to tiddlywiki@googlegroups.com.
Visit this group at https://groups.google.com/group/tiddlywiki.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/tiddlywiki/E3842A3A-E79F-401A-994D-474458EAA7AE%40gmail.com.
For more options, visit https://groups.google.com/d/optout.


Re: [tw5] Reverse getindex?

2018-11-07 Thread Hubert
Mark, thank you!

Your solution is clean and elegant and, most importantly, it works *exactly 
*as expected.
Thanks again for taking the time to help.

Best,
Hubert

On Tuesday, 6 November 2018 18:05:38 UTC, Mark S. wrote:
>
> In the interim, this may be useful:
>
> \define myfilter() [title[data##$(index)$]regexp:title[$(term)$]]
> \define value() {{data##$(index)$}}
>
> <$set name="term" value="duck">
> <$list filter="[title[data]indexes[]]" variable="index">
> <$wikify name="title" text=<>>
> <$list filter="[titleregexp]" >
>
> 
> 
> 
> 
>
> The outer list enumerates the data tiddler. The inner list checks if it 
> contains the term.
>
> -- Mark
>
> On Tuesday, November 6, 2018 at 8:59:48 AM UTC-8, Hubert wrote:
>>
>> Jeremy, thank you so much for taking the time to address my question.
>>
>> Unfortunately, coming up with a solution that could be merged with the 
>> core is going to be beyond the scope of my ability in the foreseeable 
>> future.
>>
>> Best regards,
>> Hubert
>>
>> On Tuesday, 6 November 2018 16:50:06 UTC, Jeremy Ruston wrote:
>>>
>>> Hi Hubert
>>>
>>> On 6 Nov 2018, at 15:05, Hubert  wrote:
>>>
>>> We can get the value of an index in a data dictionary by searching for 
>>> the index using getindex.
>>>
>>> Is there a way to perform a reverse operation that would find index(es) 
>>> that have the specified value?
>>>
>>> The assumption is that all indexes and their values are listed in a 
>>> single data dictionary and not across multiple/individual data dictionaries 
>>> (I know it's possible in the latter scenario).
>>>
>>>
>>> Indeed, I think it would be feasible to make a “searchindexes” filter so 
>>> that [[my data dictionary]searchindexes[foo]] would return the index names 
>>> from the input tiddlers that contain the text foo.
>>>
>>> Best wishes
>>>
>>> Jeremy.
>>>
>>>
>>> Thanks!
>>>
>>>
>>> -- 
>>> 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 tiddlywiki+...@googlegroups.com.
>>> To post to this group, send email to tiddl...@googlegroups.com.
>>> Visit this group at https://groups.google.com/group/tiddlywiki.
>>> To view this discussion on the web visit 
>>> https://groups.google.com/d/msgid/tiddlywiki/e0a5add7-8141-4de4-a2e9-55e25dce6821%40googlegroups.com
>>>  
>>> 
>>> .
>>> For more options, visit https://groups.google.com/d/optout.
>>>
>>>
>>>

-- 
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 tiddlywiki+unsubscr...@googlegroups.com.
To post to this group, send email to tiddlywiki@googlegroups.com.
Visit this group at https://groups.google.com/group/tiddlywiki.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/tiddlywiki/10d6c738-1003-449f-87d1-b30a92a637f5%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[tw5] Re: Compare two variables for equality and inequality

2018-11-07 Thread Mohammad
I think the problem is with what macro returns!

Now macro returns {{$:/PSaT/wikimanager/wiki-tiddler##wiki-title}} 
But you are write the code does not work!



-Mohammad

-- 
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 tiddlywiki+unsubscr...@googlegroups.com.
To post to this group, send email to tiddlywiki@googlegroups.com.
Visit this group at https://groups.google.com/group/tiddlywiki.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/tiddlywiki/ede98f26-c3be-4ea5-874f-c1f8f77e8139%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[tw5] Re: Compare two variables for equality and inequality

2018-11-07 Thread TonyM
I believe it was not until I used wikify to create a variable 

The Following example does not work even although <> returns 
the correct value

\define currentWiki() {{$:/PSaT/wikimanager/wiki-tiddler##wiki-title}}

<>


   <$list filter="[] [{!!wiki-owner}] +[count[]] -[[2]]">
   same {{Certificate.svg}}
   
   <$list filter="[] [{!!wiki-owner}] +[count[]] -[[1]]">
   different {{Certificate-not.svg}}
   

How ever when refactored this works

<$wikify name=this-wiki text="<>">
   <$list filter="[] [{!!wiki-owner}] +[count[]] -[[2]]">
   same {{Certificate.svg}}
   
   <$list filter="[] [{!!wiki-owner}] +[count[]] -[[1]]">
   different {{Certificate-not.svg}}
   


I stand to be corrected, but that is all I can say at this point.

Regards
Tony

On Wednesday, November 7, 2018 at 5:03:21 PM UTC+11, Mohammad wrote:
>
> Hello Tony!
>  This is really interesting! I would appreciate if you could put it inside 
> a wiki and give link for future references!
> By the way you said the variables cannot be the result of a macro call, 
> why?
>
> -Mohammad
>

-- 
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 tiddlywiki+unsubscr...@googlegroups.com.
To post to this group, send email to tiddlywiki@googlegroups.com.
Visit this group at https://groups.google.com/group/tiddlywiki.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/tiddlywiki/962c78fe-6e3d-4860-a2c3-daeba7aeca98%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.