TiddlyFox
TiddlyFox copied to clipboard
Should not try to operate on readOnly TiddlyWikis
Should include a test for "not readOnly" before asking for permission to inject the saver code. At present I am having to manually edit the versionArea script section to stop browsers with TiddlyFox installed spuriously bothering users for permission to load the saver to read-only TWs!
Hi @JohnHind aha, interesting problem! Presumably you are distributing the TW's via a file:// URI?
TiddlyFox only does it's stuff after the TW file has loaded, so it would certainly be possible to add a check the readOnly global.
We'd need to also make it possible to restore saving; I guess if someone has a zzConfig tiddler that enforces readOnly mode then they'd still be able to use a paramifier to override it.
Yes, I've used it for the documentation file in my Winsh.lua project here:
https://github.com/JohnHind/Winsh.lua/blob/master/Doc/Winsh.html
I maintain source and published versions and "publishing" is a one-way operation so once readOnly is set that file never needs saving again. But I see that others may want to be able to clear the flag and save.
Would it be safe to postpone the permission request until a save is actually first attempted?
Would it be safe to postpone the permission request until a save is actually first attempted?
That would be great, and I think could be done fairly straightforwardly.