Request for help: Packaging Stroll as a plugin

39 views
Skip to first unread message

Diego Mesa

unread,
May 21, 2020, 2:01:05 PM5/21/20
to TiddlyWikiDev
All,

David Gifford has done a lot of great work with Stroll. I offered to try and help him package it into a plugin and upload to github for easier distirbution, upgrading, etc. I, being a novice in TW development, just tried to package it using Tinka, but quickly realized its not as simple as that. Much of it was developed using things like: [tag[refs]].... [tag[stroll]] to grab on to parts of stroll, but once its all packaged in a plugin those tiddlers become shadow tiddlers so they aren't available in the filters like that. There also other whole plugins tagged with stroll, which cant really be included as sub plugins included in this one directly (or can they?)

I'm  willing to do the work and learn, I'm just wondering if anyone would be willing to help!

Thanks,
Diego

Saq Imtiaz

unread,
May 21, 2020, 3:15:34 PM5/21/20
to TiddlyWikiDev
[tag[refs]] is equivalent to [all[tiddlers]tag[refs]]

What you want is [all[shadows+tiddlers]tag[refs]]

3rd party plugins should not be packaged into a Stroll plugin. Instead a stroll file should consist of empty.html + stroll plugin + 3rd party plugins

Note that most of the benefit of hosting on github is lost if the plugin is not individual tiddlers in the repository.

Diego Mesa

unread,
May 21, 2020, 3:21:59 PM5/21/20
to TiddlyWikiDev
Saq

I am getting parts to work by changing [tag[refs]] from the implied [all[tiddlers]] to [all[shadows+tiddlers]tag[refs]] as you describe -Im just wondering if this is the best way to do this. What if a user is also using the "refs" tag? How should plugins maintain their own namespace?

Saq Imtiaz

unread,
May 21, 2020, 3:30:46 PM5/21/20
to TiddlyWikiDev
I would recommend something like $:/tags/stroll/refs

TonyM

unread,
May 21, 2020, 9:23:48 PM5/21/20
to TiddlyWikiDev
Diego,

Another approach is not to make a plugin (necessarily) but a bundle of tiddlers, You could use marios bundler or follow this tricky hack
  • Obtain the latest empty.html
  • Drag all tiddlers you want for stroll including plugins to the empty.html (Do not hit Import)
  • Once all the tiddlers you need are in the "Import Queue" clones the $:/Import tiddler, rename it say "Stroll Package".
    • At this point you can import all the tiddlers in $:/Import tiddler, save and reload and check its working.
  • Now edit the "Stroll Package" tiddler. The fields at the bottom show it is pending import, you can keep it like this and dragging Stroll Package to install it, import once the package then import all the tiddlers
    • plugin-type: import
    • status: pending
  • Or you can delete the status pending, and change plugin-type: to "plugin" and it becomes a plugin package, 
    • although not fully compliant eg readme etc.. It works.
    • Yes, references to shadows becomes necessary.

Regards
Tony
Reply all
Reply to author
Forward
0 new messages