I’m running TiddlyWiki with node.js and would like to have the following functionality: When I save a tiddler (regardless if it’s new or edited) or delete a tiddler, I’d like to automatically commit the .tid
file in a git repository with a commit message consisting of the the title and the action (Add/Update/Delete). The goal is to have a revision history of each page in a git repo, not necessarily integrated into TiddlyWiki
I’m unsure where to start
- Listen to events that are fired after the files was saved to the file system
- Implement it as a separate saver plugin
- Write a syncadaptor module that wraps the filesystem sync adaptor
- Do it independently from TiddlyWiki as a cron job and shell script that processes the output of
git status
. As a newcomer to TiddlyWiki this seems the “easiest” option to me, but would have the drawback of missing individual edits.
Do you have some pointers for me how I could best “hook” into the save/delete filesystem events?