Fair warning: This is all under development and not yet packaged up for easy
deployment
## Cinera
### Download, and prepare the parser
1. `git clone git@gitssh.handmade.network:Annotation-Pushers/Annotation-System.git`
2. `cd Annotation-System/hmmlib`
3. `make`
4. `cp hmml.a hmmlib.h ../cinera/`
5. `cd ../cinera/`
Note: For each parser update, remember to make and copy it into place
### Install Dependencies
1. curl
### Build
1. `$SHELL cinera.c`
### Run
#### Single Edition operation
cinera test.hmml
This simply generates an HTML file (and updates `cinera_topics.css` if needed)
from `test.hmml` and outputs to `out.html`
#### Project Edition operation
cinera -p ProjectID
Setting the ProjectID with the `-p` flag triggers Project Edition. In this
edition `cinera` monitors the Project Input Directory for new, edited and
deleted .hmml files, and generates one table of contents / search page and a
player page each for valid sets of annotations (or removes them, if needed).
By default all directories - input and output - are set to the current working
directory. Typical operation will involve setting these flags:
-d Project Input Directory, the directory where the .hmml files reside
-r Root Directory, path shallower than or equal to the CSS, Images and JS
directories
-R Root URL, corresponding to the Root Directory (optional if the Output
Base Directory resides in the Root Directory)
-c CSS Directory, relative to Root
-i Images Directory, relative to Root
-j JS Directory, relative to Root
-b Output Base Directory, location of the table of contents / search page
-B Output Base URL, corresponding to the Output Base Directory
-t Template Directory
-x Index Template Location, relative to Template Directory
-y Player Template Location, relative to Template Directory
#### Templates
Valid tags:
- `` _the project's full name_
- `` _the day / episode name, intended to be used
inside your own `
` element, but may be used wherever and as many times
as you want on your page_
*Index Template*
- `` _the necessary `.css` and `.js` files_
- `` _the table of contents, and search functionality_
*Player Template*
- `` _the necessary `.css` and `.js` files, and
charset setting_
- `` _ _the menu bar that typically appears above the
player in my samples_
- `` _the player_
- `` _the filter state objects and `.js` file, which
must come after both the MENUS and PLAYER tags_
*Optional tags available for use in your Player Template*
- `` _the title of the video, excluding numbering_
- `` _the unique identifer of the video as provided
by the VoD platform_
*Other available tags*
- `` _the full name of the project_
- `` _the URL where we have derived the page will be
publically accessibly, only really usable if BaseURL is set (-B)_
- ``
- ``
- ``
⋮
- ``
_Freeform buffers for small snippets of localised information, e.g. a single
element or perhaps a They correspond to the custom0 to
custom15 attributes in the [video] node in your .hmml files 0 to 11 may hold
up to 255 characters 12 to 15 may hold up to 1023 characters_
Feel free to play with templates to your heart's content. If you do anything
invalid, `cinera` will tell you what's wrong.
#### Arguments
Usage: ./cinera [option(s)] filename(s)
Options:
Paths: (advisedly universal, but may be set per-(sub)project as required)
-r
Override default root directory (".")
-R
Override default root URL ("")
IMPORTANT: -r and -R must correspond to the same location
UNSUPPORTED: If you move files from RootDir, the RootURL should
correspond to the resulting location
-c
Override default CSS directory (""), relative to root
-i
Override default images directory (""), relative to root
-j
Override default JS directory (""), relative to root
Project Settings:
-p
Set the project ID, equal to the "project" field in the HMML files
NOTE: Setting the project ID triggers PROJECT EDITION
-m
Override default default medium ("programming")
Known project defaults:
book: research
pcalc: programming
riscy: programming
chat: speech
code: programming
intro-to-c: programming
misc: admin
ray: programming
hmdshow: speech
lecture: speech
stream: programming
special: programming
obbg: programming
sysadmin: admin
-s