@Mark I didn't test that particular filter as I realized it would cause other issues. The filters in this tiddler only change the file extension, not the format its saved in. So you would get a .json file with plain text body and a .meta file. Not what we want.
The filter I used actually does nothing in this case and therefore doesn't make sense, we aren't using it in the way it is meant. This is just a way to use the fact that any tiddler matching the filter has its info/path recalculated to solve our problem. I am also unsure if the server needs restarting after the filter is added/changed, and if that might be why your filter was not working yesterday. I've added some comments on both tickets about these things, so hopefully we will end up with a more robust and consistent solution. https://github.com/Jermolene/TiddlyWiki5/issues/4761 https://github.com/Jermolene/TiddlyWiki5/pull/4630 On Saturday, July 18, 2020 at 4:10:00 PM UTC+2, Mark S. wrote: > > Thanks very much for that, Saq! > > What I don't understand (actually there's a lot I don't understand) is why > my filter extension > > [has[ismulti]then[.json]] > > didn't work (assuming I added the "ismulti" field). > > It's counter-intuitive that you have to tell the system to use "tid" all > the time in order to force it to use JSON some of the time. > > Thanks! > > On Saturday, July 18, 2020 at 4:38:09 AM UTC-7, Saq Imtiaz wrote: >> >> Mark, >> >> If you unzip the below file and drop the fileinfo-patch folder into the >> tiddlers folder and restart your server, multiline fields should correctly >> trigger saving tiddlers as .json >> >> https://github.com/saqimtiaz/sq-tw/raw/master/fileinfo-patch.zip >> >> The files: >> >> - filesystem.js and filesystemadaptor.js from Joshua's patch >> - FileSystemExtensions has the >> filter: [type[text/vnd.tiddlywiki]then[.tid]] which does nothing mostly, >> as >> it enforces the .tid extension for text/vnd.tiddlywiki which is already >> the >> default. However this forces fileInfo and the filePath to be reevaluated >> for each tiddler matching the filter. So adding a multiline field >> correctly >> switches the fileformat to .json >> >> - the fourth tiddler is testmutiline, open it and type a few >> characters into the textarea. A tiddler called HelloThere2a will be >> created >> as .tid. Add a linebreak into the textarea, the tiddler will switch to >> being saved as .json. >> >> Hope this helps until we get a proper fix. >> Cheers, >> Saq >> > -- You received this message because you are subscribed to the Google Groups "TiddlyWiki" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. To view this discussion on the web visit https://groups.google.com/d/msgid/tiddlywiki/22a3efbe-0aac-4679-8ffc-12a2f566a091o%40googlegroups.com.

