What filter to export everything except the core?

163 views
Skip to first unread message

Mark S.

unread,
Mar 27, 2020, 8:23:02 PM3/27/20
to TiddlyWiki
If I wanted to export everything from a single-file wiki necessary to make an identical node-based wiki, what filter would I use?

Thanks!
Message has been deleted

Jeremy Ruston

unread,
Mar 31, 2020, 6:57:52 AM3/31/20
to TiddlyWiki
Hi Mark

> On 28 Mar 2020, at 00:23, 'Mark S.' via TiddlyWiki <tiddl...@googlegroups.com> wrote:
>
> If I wanted to export everything from a single-file wiki necessary to make an identical node-based wiki, what filter would I use?

One can use exactly the same tiddlers in both configurations (apart from needing the tiddlyweb and filesystem plugins, but those are usually handled by reference from the tiddlywiki.info file), so the filter to use would be [is[tiddler]].

Best wishes

Jeremy

Mark S.

unread,
Mar 31, 2020, 11:44:45 AM3/31/20
to TiddlyWiki
Hi Jeremy,

I guess I should have asked for the complete magic incantation for creating tiddlers from an existing TW file.

I've tried

tiddlywiki SFG --load SFG\garden.html --render "[is[tiddler]]" --output SFG\tiddlers2

and other variations. I've looked at everything tagged "node.js" at TiddlyWiki.com. There are a couple instructions for converting tiddlers to TW files, though some of them use the older command set and one of them is for TW2 . But I couldn't find any examples for exporting individual tiddlers en masse via node.

My goal is to pour tiddlers back and forth between single file and data file formats, depending on current user requirements.

Thank you!

Mark S.

unread,
Mar 31, 2020, 3:35:21 PM3/31/20
to TiddlyWiki
Every version I try gave me an error starting like this:

Error: EINVAL: invalid argument, open 'D:\data\Wikis\temp\output\$:\boot\boot.cs
s.tid'
    at Object.openSync (fs.js:438:3)

Somewhere I'm pretty sure it promised it would handle disambiguation.

So if I do my own disambiguation/conversion :

D:\data\Wikis>tiddlywiki --verbose  --load SFG\garden.html --render "[is[tiddler]]" "[encodeuricomponent[]addsuffix[.tid]]" text/plain "$:/core/templates/tid-tiddler"

This works, but the titles are really ugly and hard to read.

After some more experimentation, I have:

tiddlywiki --verbose  --load SFG\garden.html --output SFG\tiddlers2 --render "[is[tiddler]]" "[splitregexp[\$|\*|:|/|\s]join[_]addsuffix[.tid]]" text/plain "$:/core/templates/tid-tiddler"

My concern here is that the ad-hoc way I used to convert the titles to file names might result in identical file names that will overwrite each other.

What, if anything, is the trick to get node to generate the same kind of tiddler names that it does when using --listen ?

Thanks!

Jeremy Ruston

unread,
Mar 31, 2020, 4:15:50 PM3/31/20
to tiddl...@googlegroups.com
Hi Mark

From v5.1.22, the recommended way to convert a TW5 HTML file to a wiki folder is with the savewikifolder command, see:


Prior to v5.1.22, the recommended way was to include the filesystem plugin in the wiki, causing changes to tiddlers to be written to the file system, and then to use the load command. For example:

tiddlywiki ./mywiki --load file.html

If the filesystem plugin isn’t included in the tiddlywiki.info of the wiki then it can be explicitly added on the command line:

tiddlywiki +plugins/tiddlywiki/filesystem ./mywiki --load file.html

Best wishes

Jeremy.

-- 
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 view this discussion on the web visit https://groups.google.com/d/msgid/tiddlywiki/a5cd6d7f-df91-40ce-b204-36ede819c874%40googlegroups.com.

Mark S.

unread,
Mar 31, 2020, 4:38:59 PM3/31/20
to TiddlyWiki
I see you must have meant "From v5.1.20".  Ok. That looks pretty neat!

Thanks!

Jeremy Ruston

unread,
Apr 1, 2020, 1:32:03 PM4/1/20
to tiddl...@googlegroups.com
Hi Mark

I see you must have meant "From v5.1.20".  Ok. That looks pretty neat!

The savewikifolder command is new for v5.1.22, so it’s only currently available in the prerelease

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.

Mark S.

unread,
Apr 1, 2020, 2:43:24 PM4/1/20
to TiddlyWiki
It's showing up in 5.1.21, and it has a flag that says "new in 5.1.20" .


On Wednesday, April 1, 2020 at 10:32:03 AM UTC-7, Jeremy Ruston wrote:
Hi Mark

I see you must have meant "From v5.1.20".  Ok. That looks pretty neat!

The savewikifolder command is new for v5.1.22, so it’s only currently available in the prerelease

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+unsubscribe@googlegroups.com.

Jeremy Ruston

unread,
Apr 1, 2020, 2:45:18 PM4/1/20
to tiddl...@googlegroups.com
Apologies, you’re quite right. In my defence, 2019 went rather quickly!

Best wishes

Jeremy

--
Jeremy Ruston


On 1 Apr 2020, at 19:43, 'Mark S.' via TiddlyWiki <tiddl...@googlegroups.com> wrote:


To unsubscribe from this group and stop receiving emails from it, send an email to tiddlywiki+...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/tiddlywiki/220bb53e-0649-4e4b-90ed-d0e8e129da6b%40googlegroups.com.
Reply all
Reply to author
Forward
0 new messages