From 548776e828534a216e5d8f400a4dd043a2bd9052 Mon Sep 17 00:00:00 2001 From: Jermolene Date: Mon, 6 Oct 2014 21:20:28 +0100 Subject: [PATCH] Add KaTeX static build --- bin/fullbld.sh | 1 + readme.md | 58 ++++++++++++++++++++++++++++++++++---------------- 2 files changed, 41 insertions(+), 18 deletions(-) diff --git a/bin/fullbld.sh b/bin/fullbld.sh index c54ef8a9f..736ace45b 100755 --- a/bin/fullbld.sh +++ b/bin/fullbld.sh @@ -106,6 +106,7 @@ node ./tiddlywiki.js \ --output $TW5_BUILD_OUTPUT \ --rendertiddler $:/core/save/all plugins/tiddlywiki/katex/index.html text/plain \ --rendertiddler $:/core/save/empty plugins/tiddlywiki/katex/empty.html text/plain \ + --rendertiddler $:/core/templates/static.template.html plugins/tiddlywiki/katex/static.html text/plain \ || exit 1 # /plugins/tiddlywiki/tahoelafs/index.html Demo wiki with Tahoe-LAFS plugin diff --git a/readme.md b/readme.md index 7cceed996..be28003ce 100644 --- a/readme.md +++ b/readme.md @@ -1,167 +1,189 @@

Welcome to TiddlyWiki, a non-linear personal web notebook that anyone can use and keep forever, independently of any corporation.

TiddlyWiki is a complete interactive wiki in JavaScript. It can be used as a single HTML file in the browser or as a powerful Node.js application. It is highly customisable: the entire user interface is itself implemented in hackable WikiText.

Learn more and see it in action at http://tiddlywiki.com/

Developer documentation is in progress at http://tiddlywiki.com/dev/

Installing TiddlyWiki on Node.js

  1. Install Node.js from http://nodejs.org
  2. Open a command line terminal and type:

    npm install -g tiddlywiki

    If it fails with an error you may need to re-run the command as an administrator:

    npm install -g tiddlywiki (Windows)

    sudo npm install -g tiddlywiki (Mac/Linux)

  3. Check TiddlyWiki is installed by typing:

    tiddlywiki --version

  4. In response, you should see TiddlyWiki report its current version (eg 5.0.8-beta; you may also see other debugging information reported)
  5. Try it out:
    1. tiddlywiki mynewwiki --init server to create a folder for a new wiki that includes server-related components
    2. tiddlywiki mynewwiki --server to start TiddlyWiki
    3. Visit http://127.0.0.1:8080/ in your browser
    4. Try editing and creating tiddlers

The -g flag causes TiddlyWiki to be installed globally. Without it, TiddlyWiki will only be available in the directory where you installed it. -

Using TiddlyWiki on Node.js

TiddlyWiki5 can be used on the command line to perform an extensive set of operations based on TiddlyWikiFolders, TiddlerFiles and TiddlyWikiFiles.

For example, the following command loads the tiddlers from a TiddlyWiki HTML file and then saves one of them in static HTML:

tiddlywiki --verbose --load mywiki.html --rendertiddler ReadMe ./readme.html

Running tiddlywiki 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 TiddlyWikiFolder 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 --.

tiddlywiki [<wikipath>] [--<command> [<arg>[,<arg>]]]

The available commands are: