A self-contained JavaScript wiki for the browser, Node.js, AWS Lambda etc.
Go to file
Jeremy Ruston cd36f594c5 Make the core into a plugin 2013-03-28 17:07:30 +00:00
boot Make the core into a plugin 2013-03-28 17:07:30 +00:00
core Make the core into a plugin 2013-03-28 17:07:30 +00:00
editions Docs update 2013-03-25 19:56:30 +00:00
plugins/tiddlywiki Added support for deleting tiddlers during file synchronisation 2013-03-25 20:16:12 +00:00
.gitignore Batch file cleanups 2012-11-29 21:30:53 +00:00
2bld.sh Update batch files to specify wikipath 2013-02-09 17:08:19 +00:00
bld.sh Remove erroneous verbose flag for deletion 2013-03-20 11:01:12 +00:00
dbld.sh Batch file cleanups 2012-11-29 21:30:53 +00:00
package.json Remove more pesky instances of "reusable" 2013-03-19 22:45:12 +00:00
readme.md Remove more pesky instances of "reusable" 2013-03-19 22:45:12 +00:00
serve.sh Add new clientserver edition 2013-03-10 19:28:58 +00:00
tiddlywiki.js Make the core into a plugin 2013-03-28 17:07:30 +00:00
wbld.sh Get TiddlyWiki5 in the Sky for TiddlyWeb working again 2013-03-06 16:45:13 +00:00

readme.md

Welcome to TiddlyWiki5

Welcome to TiddlyWiki5, a reboot of TiddlyWiki, the non-linear personal web notebook first released in 2004. It is a complete interactive wiki in JavaScript that can be run from a single HTML file in the browser or as a powerful node.js application.

TiddlyWiki is designed to fit around your brain, giving you a better way of managing information than traditional documents and emails. The fundamental idea is that information is more useful and reusable if we cut it up into the smallest semantically meaningful chunks tiddlers and give them titles so that they can be structured with links, tags and macros. TiddlyWiki aims to provide a fluid interface for working with tiddlers, allowing them to be aggregated and composed into longer narratives.

TiddlyWiki5 has many improvements over the original. It is currently labelled alpha, meaning it is working but incomplete. It is a great time to get involved and support its future development. You can:

Getting started with TiddlyWiki under node.js

TiddlyWiki5 can be used on the command line to perform an extensive set of operations based on tiddlers, TiddlerFiles and TiddlyWikiFiles. For example, this loads the tiddlers from a TiddlyWiki HTML file and then saves one of them in HTML:

node tiddlywiki.js --verbose --load mywiki.html --savetiddler ReadMe ./readme.html

In order to use TiddlyWiki5 on the command line you must first install node.js:

http://nodejs.org/

Usage

Running tiddlywiki.js from the command line boots the TiddlyWiki kernel, loads the core plugins and establishes an empty wiki store. It then sequentially processes the command line arguments from left to right. The arguments are separated with spaces.

The first argument is the optional path to the WikiDirectory to be loaded. If not present, then the current directory is used.

The commands and their individual arguments follow, each command being identified by the prefix --.

node tiddlywiki.js [<wikipath>] [--<command> [<arg>[,<arg>]]]

Batch Files

For trying TiddlyWiki5 out under node.js, several batch files are provided:

bld.sh builds tw5.com

This batch file builds several variants of TiddlyWiki5 for deployment on tiddlywiki.com.

By default, files are output to a folder called jermolene.github.com in the same directory as the main TiddlyWiki5 directory. You will need to create the directory before running the batch file. For example:

* /TiddlyWork/ - Directory for working with TiddlyWiki5
* /TiddlyWork/TiddlyWiki5/ - Directory containing the TiddlyWiki5 repo from GitHub
* /TiddlyWork/jermolene.github.com/ - Directory for output files

You can override the build output directory by defining the environment variable TW5_BUILD_OUTPUT. The easiest way to do this is to create a personal batch file to invoke TiddlyWik5i that first sets the environment variable and then invokes bld.sh.

The files output by bld.sh are:

  • readme.md main readme file, output to the TiddlyWiki5 directory
  • index.html TiddlyWiki5 standalone HTML file with content from the tw5.com edition
  • empty.html TiddlyWiki5 standalone HTML file with no content
  • encrypted.html TiddlyWiki5 standalone HTML file encrypted with the password password
  • static.html static HTML version of the DefaultTiddlers of the tw5.com edition
  • static/*.html and static/static.css static HTML versions of individual tiddlers

serve.sh serves tw5.com

This batch file starts TiddlyWiki5 running as an HTTP server with the content from the clientserver edition. By default, the script serves on port 8080.

To experiment with this configuration, run the script and then visit http://0.0.0.0:8080 in a browser. Currently changes do get synced to the server but the server doesn't yet save the changes back to the file system. Thus the best way to experiment with this edition is by visiting it in two different browsers, exploring how the changes made in one browser propogate to the other.

wbld.sh builds TiddlyWiki5 for TiddlyWeb

This batch file builds and deploys the code for TiddlyWiki5 in the Sky for TiddlyWeb. If you want to experiment with your own builds of TiddlyWiki5 for TiddlyWeb you could use this batch file as a base.

2bld.sh builds TiddlyWiki 2.6.5

This batch file builds TiddlyWiki 2.6.5 from the original source and then uses the opendiff program to display the differences between them.

Commands

The following commands are available:

DumpCommand

dump tiddlers

Dump the titles of the tiddlers in the wiki store

--dump tiddlers

dump tiddler

Dump the fields of an individual tiddler

--dump tiddler <title>

dump system

Dump the titles of the system tiddlers in the wiki store

--dump systems

dump config

Dump the current core configuration

--dump config

LoadCommand

Load tiddlers from 2.x.x TiddlyWiki files ( .html), .tiddler, .tid, .json or other files

--load <filepath>

SaveTiddlerCommand

Save an individual tiddler as a specified ContentType, defaults to text/html

--savetiddler <title> <filename> [<type>]

SaveTiddlersCommand

Save a set of tiddlers matching a filter as separate files of a specified ContentType (defaults to text/html) and extension (defaults to .html).

--savetiddlers <filter> <template> <pathname> [<type>] [<extension>]

For example:

--savetiddlers [!is[system]] $:/core/templates/static.tiddler.html ./static text/plain

ServerCommand

The server built in to TiddlyWiki5 is very simple. Although compatible with TiddlyWeb it doesn't support many of the features needed for robust Internet-facing usage - in particular, TiddlyWiki5 is an old-school wiki in the sense that it offers no authentication.

At the root, it serves a rendering of a specified tiddler. Away from the root, it serves individual tiddlers encoded in JSON, and supports the basic HTTP operations for GET, PUT and DELETE.

--server <port> <roottiddler> <rendertype> <servetype>

For example:

--server 8080 $:/core/tiddlywiki5.template.html text/plain text/html

The parameters are:

--server <port> <roottiddler> <rendertype> <servetype>
  • port - port number to serve from (defaults to "8080")
  • roottiddler - the tiddler to serve at the root (defaults to "$:/core/tiddlywiki5.template.html")
  • rendertype - the content type to which the root tiddler should be rendered (defaults to "text/plain")
  • servetype - the content type with which the root tiddler should be served (defaults to "text/html")

VerboseCommand

Triggers verbose output, useful for debugging

--verbose

VersionCommand

Displays the version number of TiddlyWiki.

--version

This readme file was automatically generated by TiddlyWiki5