[tw5] Re: Action equivalent of click on link and other enhancements

2019-05-24 Thread TonyM
A Related post by me is about protocol handlers 
 because 
If I can also batch process multiple links to a custom protocol handler 
even more is possible.

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/86ae3ed3-bffc-460c-b0cd-ae1ccd3d219f%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[tw5] Playing with URL protocol handlers

2019-05-24 Thread TonyM
Hi Folks,

I have just being studying URL Protocol handlers such as file: and https:

I am able to define my own such as fred: such that fred:anything opens a 
desktop app or batch and passes the full address as a parameter.

Can anyone tell be how I may configure tiddlywiki to permit the fred 
protocol to open like a link beginning with http because at the moment 
tiddlywiki thinks I am naming a tiddler.

My browsers already know this protocol because it is defined on my windows 
10 desktop, I just need to get tiddlywiki to pass it through.

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/94cf2f63-53e9-41d0-8695-9d264a5c89d3%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[tw5] Filtering an "or" condition

2019-05-24 Thread Damon Pritchett
Hello again,

I'm trying to do a filter where I'm doing a search of tiddler titles 
looking for this word or that word in the title. For example, let's say I 
have a number of tiddlers with the word vegetarian in it and another group 
with the word pasta in it. I want to find all tiddlers that have either of 
those words in the title even if the title contains both. I tried the 
examples on the Introduction to filter notation page (
https://tiddlywiki.com/#Introduction%20to%20filter%20notation), but so far 
when I do the following:

[search:title[vegetarian]] [search:title[pasta]] 

I get only the titles that have pasta or vegetarian in them. The titles 
that have both vegetarian and pasta in it do not get listed.

What is the secret sauce for having a true or and not an exclusive or?

Thanks,

Damon

-- 
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/2bb8d891-d5a5-43db-af10-7013bc645cf4%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[tw5] Re: TiddlyWiki for project management: How to deal with Tasks from different projects requiring the same title?

2019-05-24 Thread TonyM
Ed,

The easiest way would be to set up a new tiddler button that adds the 
number at the end research 1, research 2 etc...

However

When faced with this I create a new tiddler button, that names new tiddlers 
with a project suffix eg "projectshortname new tiddler" or 
"projectshortname new task" which I would then name to "projectshortname 
research" however I do not have much of a problem coming up with unique 
names such as "Research CCS for forms", and if I wanted to collect research 
tiddlers together I may tag it research, even make a new tiddler button to 
create research tiddler tasks.

But even with the above I tend to avoid tags for defining recurring items, 
I often then store a value in a field. for example project name is stored 
in a field, and I could have a task-type field = research.

Further, stored in fields I have domain (Work Personal etc...), the 
aforementioned project name, client name (if applicable), contact name 
(person if applicable) - *I call this the contex*t.

When I create a new tiddler I do so from any tiddler already with a 
context, and the new tiddler is created using the current context.

Eg in a project click to create a domain/project name task, in a client 
click to create a clientname task

The truth is you not only need unique titles to confidently find something 
again but it is a good design strategy. If you want you could use a data 
tiddler for each project and store these similarly named tasks in a 
different way.

Regards
Tony


On Saturday, May 25, 2019 at 10:30:16 AM UTC+10, Ed Edson wrote:
>
> Hello!
>
> I hope this is an appropriate question for this forum. I am starting to 
> use TiddlyWiki as a simple project management tool and am looking for some 
> advice from someone with more experience than me.
>
> I am adding a Tiddler for each new project, and then adding tasks tagged 
> with the name of the project they belong to. I generate tasks lists for 
> each project in a way similar to this. 
>  I also have a 
> table of contents to aid navigation.
>
> What is a good way to deal with projects that contain tasks with the same 
> name?
>
> For example, many of my projects involve doing a bit of research first, so 
> I will create a task called "Research". The problem is that TiddlyWiki 
> requires unique titles. In this case I cannot reuse the "Research" Tiddler 
> as the content will be different for each project.
>
> Does anyone have a good system that avoids this problem?
>
> 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/c6ef0a5d-15b8-415a-aedf-c558ace328a3%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[tw5] Action equivalent of click on link and other enhancements

2019-05-24 Thread TonyM
Folks,

I am using TiddlyDesktop to launch apps from a button

Part if this code is
<$list filter="[has[desktop-link]]">
   <$list filter="[is[current]get[desktop-link]] ] -[has[draft.of]]" 
variable="link">
  > ><$transclude tiddler=<
>/>
   

in the above an svg file has a desktop-link field with the 
file://path/executable.exe, it displays the image and you click it to open 
the app.

Clicking on the button or a link the application opens on my desktop. Great 
so far.

*I would like to find an Action equivalent of a click on a link, so I can 
create a Button to open multiple apps in one click.*
This should also hold true for a list of urls

Any suggestions would be appreciated.

*Running batch/command or other scripts*
I know bob permits this however I am trying to simplify if for single file 
wikis on TiddlyDesktop
This does not work when the file is a batch file, thus the next item
I could launch an executable that runs the batch file but I can't pass any 
parameters to the links, so the only option I see is to write batch files 
and convert them to exe's which is time consuming and needs to be done 
every time.

*Passing parameter with a file: link*
html allows for passing information on the urls but is there a way to pass 
parameters on the file: link?

Thanks if you have anything to suggest
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/7a5f1b15-ab33-40d0-92f9-99b7af4a3123%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[tw5] TiddlyWiki for project management: How to deal with Tasks from different projects requiring the same title?

2019-05-24 Thread Ed Edson
Hello!

I hope this is an appropriate question for this forum. I am starting to use 
TiddlyWiki as a simple project management tool and am looking for some 
advice from someone with more experience than me.

I am adding a Tiddler for each new project, and then adding tasks tagged 
with the name of the project they belong to. I generate tasks lists for 
each project in a way similar to this. 
 I also have a 
table of contents to aid navigation.

What is a good way to deal with projects that contain tasks with the same 
name?

For example, many of my projects involve doing a bit of research first, so 
I will create a task called "Research". The problem is that TiddlyWiki 
requires unique titles. In this case I cannot reuse the "Research" Tiddler 
as the content will be different for each project.

Does anyone have a good system that avoids this problem?

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/58cb6363-e67f-4abf-8d6b-60ca006d6861%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[tw5] Re: ccTiddly Migration back to TiddlyWiki

2019-05-24 Thread TonyM
Eric,

I am not very familiar with ccTiddly however does it not have an export 
mechanisium? 

Along with TiddlyWiki I use WordPress and I hope to develop a higher level 
of integration between the two. Somewhat opposite I would love to get a 
saver to save tiddlers into a MySQL BD, perhaps even one that WordPress 
could pull from.

However as Mark says PHPMyAdmin will let you export MySQL databases and the 
you can develop a way to import it into any tiddlywiki. I will look to see 
if there is a best way to do this. This method is however an "under the 
hood" solution, and an export of data from the "front end" (browser access 
to your wiki) would possibly be better and quicker if its possible.

Have you worked through the options for hosting your TiddlyWikis on the 
server? Feel free to raise that here for more advice from the community. I 
imaging node JS with authentication or the Bob plugin may be the best way 
to go. 

Regards
Tony




On Saturday, May 25, 2019 at 4:08:11 AM UTC+10, Eric Kofoid wrote:
>
> Years ago, I set up a TiddlyWiki for my lab. Some foreign colleagues 
> expressed interest in it, so I converted it to ccTiddly to enable 
> server-side sharing from our lab webpage.  The wiki has lain dormant for 
> some time and I now wish to reanimate it. The University will no longer 
> allow ccTiddly for security reasons. More to the point, ccTiddly won't even 
> work when I migrate the wiki to our new server as it doesn't play well with 
> the most recent version of PHP and, I suspect, with the server operating 
> system itself.
>
> I would like to convert the wiki back to TiddlyWiki in its newest version 
> and use something like the WebServer plugin to publish. However, since all 
> ccTiddly content is stored in a MySQL database, I've found myself 
> laboriously copying a tiddler at a time to the new setup. Is there an 
> easier, more mechanized way to do this?
>
> I have also been experimenting with the WordPress YadaWiki plugin, which 
> seems quite nice but not as simple or efficient to use as TiddlyWiki. 
> Nevertheless, has anyone had any experience moving tiddler pages to it in a 
> scriptable fashion?
>
> Cheers,
>
> Eric
>

-- 
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/c984ef34-983a-478f-81dd-a11e89fc46d4%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[tw5] Re: Shopping for Android & Windows -- Systems the world uses ... :-)

2019-05-24 Thread TonyM
Thanks Gentlemen, mark and josiah for your considered responses.

I will read through this again, perhaps more than once and think deeply about 
it. Like you both I would love for us to find nirvana for tiddlywiki saves.

Whilst I have being a script kiddy with PowerShell I have a very high level of 
batch programming skills .bat and .cmd and have automated windows desktop and 
servers many times. As mentioned before I call these monitoring scripts 
sentenials, and they capture files or data. 

A solution such as this may be applicable to more than tiddlywiki.

Something about the current solution concerns me when it comes to first time 
users and making it as simple as possible, but you have developed a good 
approach. Let me see if I can add to this.

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/bf29e3ac-ae34-46ae-b63a-5ee2c7fc9aa3%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[tw5] Re: macro buttons getting repeat endings in code (in Bob?)

2019-05-24 Thread Dave
Hi, thank you.  For sure its not a stuck key or clipboard thing.  It seems 
to happen in the background.  For example I found one today that it had 
happened to twice:

<>ersion>>ersion>>


(that was the sole content of the tiddler, obviously a "Version" tiddler)

I'll keep looking into it and if I figure out anything I'll post back in 
case anyone else has this in the future.  (At least its adding info rather 
than taking away, ha ha)

-- 
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/d47bcec2-68ad-4531-a7ce-3d0c2e1e1a7f%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[tw5] ccTiddly Migration back to TiddlyWiki

2019-05-24 Thread Eric Kofoid
Years ago, I set up a TiddlyWiki for my lab. Some foreign colleagues 
expressed interest in it, so I converted it to ccTiddly to enable 
server-side sharing from our lab webpage.  The wiki has lain dormant for 
some time and I now wish to reanimate it. The University will no longer 
allow ccTiddly for security reasons. More to the point, ccTiddly won't even 
work when I migrate the wiki to our new server as it doesn't play well with 
the most recent version of PHP and, I suspect, with the server operating 
system itself.

I would like to convert the wiki back to TiddlyWiki in its newest version 
and use something like the WebServer plugin to publish. However, since all 
ccTiddly content is stored in a MySQL database, I've found myself 
laboriously copying a tiddler at a time to the new setup. Is there an 
easier, more mechanized way to do this?

I have also been experimenting with the WordPress YadaWiki plugin, which 
seems quite nice but not as simple or efficient to use as TiddlyWiki. 
Nevertheless, has anyone had any experience moving tiddler pages to it in a 
scriptable fashion?

Cheers,

Eric

-- 
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/143a5f28-edfc-47ce-9710-2cc0f199d2bb%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[tw5] Re: Shopping for Android & Windows -- Systems the world uses ... :-)

2019-05-24 Thread 'Mark S.' via TiddlyWiki


On Friday, May 24, 2019 at 4:13:39 AM UTC-7, @TiddlyTweeter wrote:
>
>
> But it won't work if you save someplace not being monitored.
>
>>
>>- Can we build this to cater for every Operating system?
>>
>> Linux has a rich library of shell tools. I'm reasonably confident that 
it's possible to do the same with Linux. The one additional bit of code 
that people will need from their distributions is the "sleep function". 
Strangely, that ability isn't built-in to the shell. 

Sadly, I had started writing code for Linux, but I foolishly was writing on 
a persistent flash drive which turned out to not be all that persistent. So 
later. 

I said I was not a Powershell aficionado (last week I didn't even know how 
to spell PowderSell). I'm also not a bash aficionado. I know there are 
people here who are really good with shell scripting. Maybe one of them 
will take an interest before I get around to it.

Mac has a linux-like environment. So presumably any scripts for Linux will 
be nearly ready for anyone on Mac. Hopefully someone from the Mac world 
will take an interest, since I don't have a Mac device.


> Tony, FYI *the only issue I see is TIMING.* The downside of using an 
> external script to native TW methods on saving is that Restore is that you 
> need to POLL the Wiki often to keep contemporaneous. This may be slightly 
> confusing to end-users under some circumstances. 
>
 
The only time you need to reload is if you're installing a plugin. 
Anyone advanced enough to be installing a plugin will be 
advanced enough to know how the "restore" mechanism works. Right? ;-)

It needs something more catchy than the "restore"  terminology. Maybe the 
"Phoenix", "dezombifier", or "nine-lives" process. Something to think about.

-- Mark

-- 
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/a17c98cf-c70a-4b84-bc73-f1922fe95a55%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[tw5] Re: Query -- Are we neglecting "Restore" from default "Download Saves"?

2019-05-24 Thread 'Mark S.' via TiddlyWiki
Hi TiddlyTweeter,

On Friday, May 24, 2019 at 2:29:48 AM UTC-7, @TiddlyTweeter wrote:
>
> Ciao Mark S.
>
> It works! :-)
>
> Some initial comments .
>
> *Tested on ...*
>
> Windows 10 64-bit tablet
>
> PowerShell: 6 
>
> Browsers: Vivaldi, Firefox, Edge, Chrome, 2 other Chromium
>
>
>
> Wow -- very thorough. I should say, your setup outstrips mine. I think I'm 
still on PS 4, Windows 7. Every day my Google News feeds reports problems 
people are having with updates on Windows 10. Makes me wonder if I should 
stick with Windows when support for 7 is dropped.
 

> TEETHING PROBLEMS
>
>  -- PowerShell would not run the script till I ran the (session only) 
> command ...
>
> "Set-ExecutionPolicy -scope CurrentUser -executionPolicy Unrestricted" 
>
>
>
How did you discover the secret recipe? I wonder if that's a PS6 thing? I 
imagine that it's possible to set this in your profile.
 

>
> BROWSERS -- SMALL ISSUE 
>
>  To my surprise not all modern browsers save the version number exactly 
> the same way. Both "name (2).html" and "name(2).html" occur.
>
>
> Well, they should both match the stem, so it should still be OK.
 

> STEMMING
>
> I don't understand how to do it but I think the stemming issue with 
> possible overwrite could be avoided by using a regular expression rather 
> than the general wildcard?
> This looks like it might work  
>
> "$stem(\s*\(\d+\))?$"
>
> But I'm unclear how PowerShell invokes the matching it can do (
> https://docs.microsoft.com/en-us/powershell/module/microsoft.powershell.core/about/about_regular_expressions?view=powershell-6
> ).
>
>
> That document explains how to do string matching. File globbing looks like 
regular expressions, but it's not. Possibly it would be possible to insert 
code that analyzes the output as strings. So one line of code would become 
10 ;-)
but it's unclear -- is there an actual problem that would be fixed by this 
approach?
 

> INSTANCES?
>
> Just a thought for later. Based on my working practice.
>
> In actual usage I'd be more likely to set "$waitSeconds" to 600 since I 
> don't write that much.
>
> I've been running several days with 180 seconds. I assume that the smaller 
the number the larger performance hit. But that hit is likely still way 
less than the browser itself. On my system it's less than the node.js 
instance. And uses a fourth of the internal memory.


 

> What I'm interested in knowing is if one could run a second instance of 
> the script--identical except it just does a restore of wiki and then exits? 
>
> For the moment you could just stop and restart the script. It should be 
possible to add an argument to the code so you could run it like 
'tw_launch_all.ps1 -mode="onetime" ' and it would run just once.

 

>
> FURTHER TESTS
>
> --- I will play with running it via a batch file. 
>
>
Here's the code I used to launch from a batch :

powershell -executionpolicy bypass -File .\launch_all_tw.ps1 

It might work for you too.

Thanks!
-- Mark

-- 
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/45e348ae-b677-44c9-9381-e03528576941%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[tw5] Re: Shopping for Android & Windows -- Systems the world uses ... :-)

2019-05-24 Thread @TiddlyTweeter
Ciao TonyM

I been playing with Mark S.' PowerShell solution 
(https://groups.google.com/d/msg/tiddlywiki/tMLfNs1K3JU/gkrGu-ubAQAJ).

My comments are based on experiments with that.

TonyM wrote:
>
> So we can say "this method allows you to open your TiddlyWiki from the 
> "original file location" (where ever you choose), it saves the TiddlyWiki 
> in the browsers "download" location, but this file is synchronised back to 
> the original location?
>

YES. Though I think "Restored" is a better description since the TW saved 
it. Its not a sync on latest. Its restore of latest. I think.
 

> When Tiddlywiki is set to save automatically, each time it saves, the next 
> version filename is used. 
>
>- Will it work for the different browsers?
>
> YES. That's the point! I works with ANY modern browser. 

For instance: Open three browsers with the same TW. Download save in each. 
The latest version gets restored regardless. 

>
>- Need they alternate configurations?
>
> NO.

Footnote: there are small differences in how some Browsers save the version 
naming. They are easily dealt with in the restore name matching.
 

>
>- I assume we need to set *one* "original location", does this need to 
>be set in the command file?
>
> Most users, I think will use the Windows "default" downloads location that 
any browser you install starts with. But, longer term, it should be 
possible to monitor more than one location if a user has set up their 
browsers to save to different places. Right now the script just monitors 
one (by being in it). I think this is an issue of "how tech do you want to 
get?" But ground zero is one monitored directory. The rest is a matter of 
further coding. I don't want to load Mark S. up with work when its maybe 
not needed.

His thought about this method is, I think, good.  And he needs time and 
appreciation.
 

> Must "let me choose where I download files" be disabled?


NO. 

But it won't work if you save someplace not being monitored.

>
>- Can we build this to cater for every Operating system?
>
> Probably.

The back story is that precisely because of the demise of the old methods 
the browsers had to converge on some kind of consistent method on naming 
and download directory, whatever platform. 

Likely an unintended consequence, but basically all modern browsers 
inter-acknowledge on download saving. PowerShell solution on Windows should 
be translatable to other OS. The principal of "Restore" is not complicated.


Tony, FYI *the only issue I see is TIMING.* The downside of using an 
external script to native TW methods on saving is that Restore is that you 
need to POLL the Wiki often to keep contemporaneous. This may be slightly 
confusing to end-users under some circumstances. 

Say I monitor with the script my wiki every 10 minutes but saved 5 minutes 
ago ... if I refresh then the changes won't show. 

Mark set the default polling in test to 10 seconds. I'm not sure I'd use 
that but I think that is part of the reason--so its very likely the 
auto-restore is in line with expectations of what you entered in the wiki.

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/1847fc18-abb6-491b-b0f3-da0247201d8a%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[tw5] Re: Query -- Are we neglecting "Restore" from default "Download Saves"?

2019-05-24 Thread @TiddlyTweeter
Ciao Mark S.

It works! :-)

Some initial comments .

*Tested on ...*

Windows 10 64-bit tablet

Browsers: Vivaldi, Firefox, Edge, Chrome, 2 other Chromium



TEETHING PROBLEMS

 -- PowerShell would not run the script till I ran the (session only) 
command ...

"Set-ExecutionPolicy -scope CurrentUser -executionPolicy Unrestricted" 


I'm not sure that's a healthy way to do it, but it worked :-).


BROWSERS -- SMALL ISSUE 

 To my surprise not all modern browsers save the version number exactly the 
same way. Both "name (2).html" and "name(2).html" occur.


STEMMING

I don't understand how to do it but I think the stemming issue with 
possible overwrite could be avoided by using a regular expression rather 
than the general wildcard?
This looks like it might work  

"$stem(\s*\(\d+\))?$"

But I'm unclear how PowerShell invokes the matching it can do (
https://docs.microsoft.com/en-us/powershell/module/microsoft.powershell.core/about/about_regular_expressions?view=powershell-6
).


INSTANCES?

Just a thought for later. Based on my working practice.

In actual usage I'd be more likely to set "$waitSeconds" to 600 since I 
don't write that much.

What I'm interested in knowing is if one could run a second instance of the 
script--identical except it just does a restore of wiki and then exits? 

An "Instant Restore". 

The case use is a common one for me ... I installed a plugin and need to do 
a refresh. Rest of the time I rarely need a restore, just saves (downloads).


FURTHER TESTS

--- I will play with running it via a batch file. 

--- See how it works with portable addressing (not for download folder, but 
for everything else).

Many thanks!
Josiah


On Monday, 20 May 2019 23:41:19 UTC+2, Mark S. wrote:
>
> I'm not a PowerShell aficionado, so even a short script takes some time. 
> If you're feeling daring, and have *backups*, you can try.
>
> At the top of the script is a list of your file stem names. They should 
> match the capitalization of your real files because sometimes Windows gets 
> confused.
>
> The second list is the list of the directories those respective stems go 
> in. There should be a one-to-one correlation. Maybe tomorrow I will learn 
> how to split out file name/paths so that two lists are not necessary ;-)
>
> There's a variable that sets how many seconds to wait before checking the 
> files again. I have it set to 10 seconds.
>
> To launch, open a powershell, go to the downloads directory used by your 
> browser, which should also be where you put the script, and type 
> ./launch_all_tw.ps1 
>
> To launch from a regular batch file would take a magic invocation, so 
> that's why I'm starting with the powershell.
>
> I had to add a kludge factor of 1 second to get the datestamp to compare 
> correctly. Possibly this would mean that if you did two rapid-fire changes 
> in a row, the 2nd one might not be picked up. But I don't know. It might be 
> fine.
>
> A script for Linux would be similar, but need completely different code.
>  
> -- Mark
>
>
>
>
> # File Stem names. Capitalize per actual file name.
> # Stem must be absolutely unique! Otherwise it might detect wrong file.
> $stemlist = @("notes","Todo")
>
> # List of target directories in same order as stem names
> $dirlist = @("D:\data\Wikis\notes","D:\data\TW2014")
>
> # How many seconds to wait before checking again.
> $waitSeconds = 10
>
> #-- SOURCE DIRECTORY -- NOT USED YET --
> $downloaddir = "C:\Users\Mark\Downloads"
>
>
> while(1) {
> for($i=0;$i -lt $stemlist.Length; $i++) {
>   $stem = $stemlist[$i]
>   $stem
>   $dir = $dirlist[$i]
>   #$dir
>   $copyme = ls $stem*.html | sort LastWriteTime | select -last 1
>   $copyme = $copyme.FullName
>   #$copyme
>   $destination = Get-Item  "$dir\$stem.html"
>   $source = Get-Item "$copyme" 
>   #echo Source: $source.LastWriteTime
>   #echo Destination: $destination.LastWriteTime 
>   If($source.LastWriteTime -gt $destination.LastWriteTime.addSeconds(1
> ) ) {
>   #echo "Source: " $source.LastWriteTime "greater than " 
> $destination.LastWriteTime.addSeconds(1) 
> Copy-Item $copyme -Destination "$dir\$stem.html"
> echo "Copying $copyme to $dir\$stem.html"
>   } Else {
> echo "Will not be copying"
>   }
> }
> echo "Going to sleep..."
> start-sleep -seconds $waitSeconds 
> }
>
>
>
>
>
>
> On Monday, May 20, 2019 at 6:05:35 AM UTC-7, @TiddlyTweeter wrote:
>>
>> At the moment, on modern browsers, saving TW without any custom saver, 
>> means the save ends up in "Downloads".
>>
>> We have no tool to "auto resurrect" and copy back that save for those 
>> kinds of saves. Copying back has to be manual and can get complicated in a 
>> forest of downloads.
>>
>> The more I think about this the more odd it seems.
>>
>> I mean, with an "AUTO-RESTORE" from saves in Download to a wiki directory 
>> ANY browser could be used and with ANY version of TW. We would not be 
>> 

[tw5] Re: macro buttons getting repeat endings in code (in Bob?)

2019-05-24 Thread TonyM
Dave,

In my own experience it is unique. That is why I have called for you to 
provide more information.

One more thing to consider, had you copied and pasted the additional text 
recently, or was it in the clipboard?

The reason I ask is I have had somewhat similar problems, which was 
ultimately due to a "stuck" key on my keyboard. In which case turn the 
keyboard upside down on your lap and try a drum solo on it (don't scare 
your neighbors). You will be surprised what falls out.

Regards
Tony

On Friday, May 24, 2019 at 12:18:14 PM UTC+10, Dave wrote:
>
>
>>
>> The example you give is not clearly a button!
>>
>> Oops, you're right - I had intended to post about this earlier and that 
> example was a button code...  Most if the time its showing up at buttons I 
> use fairly frequently
>
>  
>
>> Are you simply typing your macro in, or using a custom editorTool Bar 
>> button or something? This append then occurs after you save?
>>
> no, just normal saving.  It never happens on screen, always after I go 
> away and come back later
>  
>
>>
>> If you can find out how to make it occur repeatedly try disabling you 
>> plugins on at a time until it not longer occurs to identify the possible 
>> cause.
>>
>> Also check for system tiddlers that have being overridden for a possible 
>> error. 
>>
>> If this is occurring systematically understanding how it happens could be 
>> an opportunity for innovations.
>>
>
>  yes, I'll keep an eye out for those things.  Just thought maybe someone 
> might recognise this problem as its fairly unique (seems to me anyway)
>

-- 
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/31b9cb57-5016-4bab-8da3-6a5a04e20598%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[tw5] Re: Shopping for Android & Windows -- Systems the world uses ... :-)

2019-05-24 Thread TonyM
Mark,

Please correct me if in the following words, I am incorrect. Answering the 
questions as well please. 

So we can say "this method allows you to open your TiddlyWiki from the 
"original file location" (where ever you choose), it saves the TiddlyWiki 
in the browsers "download" location, but this file is synchronised back to 
the original location?

When Tiddlywiki is set to save automatically, each time it saves, the next 
version filename is used. 

   - Is there any popup dialogue you have to complete?
   - Will it work for the different browsers?
  - Need they alternate configurations?
   - I assume we need to set *one* "original location", does this need to 
   be set in the command file?
   - Must "let me choose where I download files" be disabled?
   - Can we build this to cater for every Operating system?

If there are any limitations I would be happy to work with you to try and 
eliminate them, at least on Windows.

I have this vision that such a solution could have the instructions and the 
necessary "code" ie command or script files built into empty.html (very low 
overhead) and the method by which to install the code locally.

Yours with a view to collaboration and simplifying tiddlywiki access.
Tony

On Friday, May 24, 2019 at 1:08:31 PM UTC+10, Mark S. wrote:
>
> The default save mechanism can be set to not write over, but to 
> automatically save as a series of files MyFile, MyFile (1), MyFile (2) 
>   This happens quietly in the background. You can change settings in 
> your TW file so that it even happens automatically whenever you change the 
> TW file. The batch code finds the most recent one to copy to the file's 
> original home directory. There's nothing really confusing about it ... 
> unless you're trying to view it that way. 
>
>
>
>
> On Thursday, May 23, 2019 at 6:26:50 PM UTC-7, TonyM wrote:
>>
>> Mark,
>>
>> I am not saying that. However if users can be easily confused, or server 
>> alternatives simple to install I believe they can compete with such 
>> solutions.
>>
>> The default save mechanism where you must select the destination and 
>> overwrite the same file, if your browser permits, is easy to loath after a 
>> few saves, and discorages saves. If the folder is under the browser it 
>> makes it harder for people to think of the wikis as simple "documents" to 
>> be managed and cloned etc...
>>
>> I am in favor of solutions like you propose, I wrote some myself years 
>> ago. I call the process of monitoring files a "sentential process", 
>> watching for change. My experience is they are somewhat "britial", however 
>> if they can be packaged for installation, and address multiple platforms 
>> they could be excellent. One avenue, ironically, is on TiddlyDesktop it is 
>> easy to include instructions for installing a sentential from code stored 
>> in tiddlers, because of the desktop interaction possibilities. I think the 
>> sentential solution may be a good choice along with other desktop 
>> interactive solutions. If people want a higher level of desktop interaction 
>> a sentential solution may be good for more than tiddlywiki.
>>
>> When it comes to using a server package it can be hosted by default on 
>> the local host only, which keeps it fairly secure and less hackable, and 
>> after all, many things are "served" today.
>>
>> Regards
>> Tony
>>
>>
>>
>>
>> On Friday, May 24, 2019 at 4:00:57 AM UTC+10, Mark S. wrote:
>>>
>>> On Wednesday, May 22, 2019 at 6:31:40 PM UTC-7, TonyM wrote:
>>>
>>> >>   Meanwhile,  a batch file with less than a hundred lines of code can 
>>> provide the features that you do need. 
>>>
>>> > If this means keeping the saved wikis under the browser this adds 
>>> complexity to the workings,
>>> > more places for error and loss. I stand to be corrected on this.
>>> 
>>> So  you're saying that using the native, automatic, absolutely
>>> safe and fool proof default save mechanism is COMPLEX, but using a
>>> full-blown, hackable web server 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/487c7bf5-7fe5-4fbe-affd-4539575aaeef%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.