table of contents
- NAME
- SYNOPSIS
- SISU - MANUAL,
- WHAT IS SISU?
- 1. INTRODUCTION - WHAT IS SISU?
- 2. COMMANDS SUMMARY
- 2.1 DESCRIPTION
- 2.2 DOCUMENT PROCESSING COMMAND FLAGS
- 3. COMMAND LINE MODIFIERS
- 4. DATABASE COMMANDS
- 5. SHORTCUTS, SHORTHAND FOR MULTIPLE FLAGS
- 5.1 COMMAND LINE WITH FLAGS - BATCH PROCESSING
- 6. HELP
- 6.1 SISU MANUAL
- 6.2 SISU MAN PAGES
- 6.3 SISU BUILT-IN INTERACTIVE HELP
- 7. INTRODUCTION TO SISU MARKUP[^10]
- 7.1 SUMMARY
- 7.2 MARKUP EXAMPLES
- 7.2.1 ONLINE
- 7.2.2 INSTALLED
- 8. MARKUP OF HEADERS
- 8.1 SAMPLE HEADER
- 8.2 AVAILABLE HEADERS
- 9. MARKUP OF SUBSTANTIVE TEXT
- 9.1 HEADING LEVELS
- 9.2 FONT ATTRIBUTES
- 9.3 INDENTATION AND BULLETS
- 9.4 HANGING INDENTS
- 9.5 FOOTNOTES / ENDNOTES
- 9.6 LINKS
- 9.6.1 NAKED URLS WITHIN TEXT, DEALING WITH URLS
- 9.6.2 LINKING TEXT
- 9.7 GROUPED TEXT
- 9.7.1 TABLES
- 9.7.2 POEM
- 9.7.3 GROUP
- 9.7.4 CODE
- 9.8 ADDITIONAL BREAKS - LINEBREAKS WITHIN OBJECTS, COLUMN AND PAGE-BREAKS
- 9.8.1 LINE-BREAKS
- 9.8.2 PAGE BREAKS
- 9.9 BOOK INDEX
- 10. COMPOSITE DOCUMENTS MARKUP
- 11. MARKUP SYNTAX HISTORY
- 11.1 NOTES RELATED TO FILES-TYPES AND MARKUP SYNTAX
- 12. SISU FILETYPES
- 12.1 .SST .SSM .SSI MARKED UP PLAIN TEXT
- 12.1.1 SISU TEXT - REGULAR FILES (.SST)
- 12.1.2 SISU MASTER FILES (.SSM)
- 12.1.3 SISU INSERT FILES (.SSI)
- 12.2 SISUPOD, ZIPPED BINARY CONTAINER (SISUPOD.ZIP, .SSP)
- 13. EXPERIMENTAL ALTERNATIVE INPUT REPRESENTATIONS
- 13.1 ALTERNATIVE XML
- 13.1.1 XML SAX REPRESENTATION
- 13.1.2 XML DOM REPRESENTATION
- 13.1.3 XML NODE REPRESENTATION
- 14. CONFIGURATION
- 14.1 DETERMINING THE CURRENT CONFIGURATION
- 14.2 CONFIGURATION FILES (CONFIG.YML)
- 15. SKINS
- 15.1 DOCUMENT SKIN
- 15.2 DIRECTORY SKIN
- 15.3 SITE SKIN
- 15.4 SAMPLE SKINS
- 16. CSS - CASCADING STYLE SHEETS (FOR HTML, XHTML AND XML)
- 17. ORGANISING CONTENT - DIRECTORY STRUCTURE AND MAPPING
- 17.1 DOCUMENT SOURCE DIRECTORY
- 17.1.1 GENERAL DIRECTORIES
- 17.2 DOCUMENT OUTPUT DIRECTORY STRUCTURES
- 17.2.1 OUTPUT DIRECTORY ROOT
- 17.2.2 ALTERNATIVE OUTPUT STRUCTURES
- 17.2.3 BY LANGUAGE
- 17.2.4 BY FILETYPE
- 17.2.5 BY FILENAME
- 17.2.6 REMOTE DIRECTORIES
- 17.2.7 SISUPOD
- 17.3 ORGANISING CONTENT
- 18. HOMEPAGES
- 18.1 HOME PAGE AND OTHER CUSTOM BUILT PAGES IN A SUB-DIRECTORY
- 18.2 HOME PAGE WITHIN A SKIN
- 19. MARKUP AND OUTPUT EXAMPLES
- 19.1 MARKUP EXAMPLES
- 20. SISU SEARCH - INTRODUCTION
- 21. SQL
- 21.1 POPULATING SQL TYPE DATABASES
- 22. POSTGRESQL
- 22.1 NAME
- 22.2 DESCRIPTION
- 22.3 SYNOPSIS
- 22.4 COMMANDS
- 22.4.1 CREATE AND DESTROY DATABASE
- 22.4.2 IMPORT AND REMOVE DOCUMENTS
- 23. SQLITE
- 23.1 NAME
- 23.2 DESCRIPTION
- 23.3 SYNOPSIS
- 23.4 COMMANDS
- 23.4.1 CREATE AND DESTROY DATABASE
- 23.4.2 IMPORT AND REMOVE DOCUMENTS
- 24. INTRODUCTION
- 24.1 SEARCH - DATABASE FRONTEND SAMPLE, UTILISING DATABASE AND SISU FEATURES,
- 24.2 SEARCH FORM
- 25. SISU_WEBRICK
- 25.1 NAME
- 25.2 SYNOPSIS
- 25.3 DESCRIPTION
- 25.4 SUMMARY OF MAN PAGE
- 25.5 DOCUMENT PROCESSING COMMAND FLAGS
- 25.6 FURTHER INFORMATION
- 25.7 AUTHOR
- 25.8 SEE ALSO
- 26. REMOTE SOURCE DOCUMENTS
- REMOTE DOCUMENT OUTPUT
- 27. REMOTE OUTPUT
- 27.1 COMMANDS
- 27.2 CONFIGURATION
- 28. REMOTE SERVERS
- 29. QUICKSTART - GETTING STARTED HOWTO
- 29.1 INSTALLATION
- 29.1.1 DEBIAN INSTALLATION
- 29.1.2 RPM INSTALLATION
- 29.1.3 INSTALLATION FROM SOURCE
- 29.2 TESTING SISU, GENERATING OUTPUT
- 29.2.1 BASIC TEXT, PLAINTEXT, HTML, XML, ODF, EPUB
- 29.2.2 LATEX / PDF
- 29.2.3 RELATIONAL DATABASE - POSTGRESQL, SQLITE
- 29.3 GETTING HELP
- 29.3.1 THE MAN PAGES
- 29.3.2 BUILT IN HELP
- 29.3.3 THE HOME PAGE
- 29.4 MARKUP SAMPLES
- 30. EDITOR FILES, SYNTAX HIGHLIGHTING
- 31. HOW DOES SISU WORK?
- 32. SUMMARY OF FEATURES
- 33. HELP SOURCES
- 33.1 MAN PAGES
- 33.2 SISU GENERATED OUTPUT - LINKS TO HTML
- 33.2.1 WWW.SISUDOC.ORG
- 33.3 MAN2HTML
- 33.3.1 LOCALLY INSTALLED
- 33.3.2 WWW.JUS.UIO.NO/SISU
- SEE ALSO
- HOMEPAGE
- AUTHOR
sisu(1) | SiSU | sisu(1) |
NAME¶
sisu - documents: markup, structuring, publishing in multiple standard formats, and searchSYNOPSIS¶
sisu [-abCcDdeFGghIikLMmNnoPpQqRrSsTtUuVvWwXxYyZ_0-9] [filename/wildcard]SISU - MANUAL,¶
RALPH AMISSAHWHAT IS SISU?¶
1. INTRODUCTION - WHAT IS SISU?¶
SiSU is a framework for document structuring, publishing (in multiple open standard formats) and search, comprising of: (a) a lightweight document structure and presentation markup syntax; and (b) an accompanying engine for generating standard document format outputs from documents prepared in sisu markup syntax, which is able to produce multiple standard outputs (including the population of sql databases) that (can) share a common numbering system for the citation of text within a document.2. COMMANDS SUMMARY¶
2.1 DESCRIPTION¶
SiSU is a document publishing system, that from a simple single marked-up document, produces multiple output formats including: plaintext, html, xhtml, XML, epub, odt (odf text), LaTeX, pdf, info, and SQL (PostgreSQL and SQLite), which share text object numbers ("object citation numbering") and the same document structure information. For more see: <http://www.jus.uio.no/sisu>2.2 DOCUMENT PROCESSING COMMAND FLAGS¶
- -a [filename/wildcard]
- produces plaintext with Unix linefeeds and without markup,
(object numbers are omitted), has footnotes at end of each paragraph that
contains them [ -A for equivalent dos (linefeed)
output file] [see -e for endnotes]. (Options
include: --endnotes for endnotes --footnotes for footnotes at the end of
each paragraph --unix for unix linefeed (default) --msdos for msdos
linefeed)
- -b [filename/wildcard]
- see --xhtml
- --by-*
- see --output-by-*
- -C
- configure/initialise shared output directory files
initialize shared output directory (config files such as css and dtd files
are not updated if they already exist unless modifier is used). -C
--init-site configure/initialise site more extensive than -C on its own,
shared output directory files/force update, existing shared output config
files such as css and dtd files are updated if this modifier is used.
- -CC
- see --configure
- -c [filename/wildcard]
- see --color-toggle
- --color-toggle [filename/wildcard]
- screen toggle ansi screen colour on or off depending on
default set (unless -c flag is used: if sisurc colour default is set to
'true', output to screen will be with colour, if sisurc colour default is
set to 'false' or is undefined screen output will be without colour).
Alias -c
- --configure
- configure/initialise shared output directory files
initialize shared output directory (config files such as css and dtd files
are not updated if they already exist unless modifier is used). The
equivalent of: -C --init-site configure/initialise site, more extensive
than -C on its own, shared output directory files/force update, existing
shared output config files such as css and dtd files are updated if -CC is
used.
- --concordance [filename/wildcard]
- produces concordance (wordmap) a rudimentary index of all
the words in a document. (Concordance files are not generated for
documents of over 260,000 words unless this limit is increased in the file
sisurc.yml). Alias -w
- -D [instruction] [filename]
- see --pg
- -d [--db-[database type (sqlite|pg)]] --[instruction] [filename]
- see --sqlite
- --dal [filename/wildcard/url]
- assumed for most other flags, creates new intermediate
files for processing (document abstraction) that is used in all subsequent
processing of other output. This step is assumed for most processing
flags. To skip it see -n. Alias -m
- --delete [filename/wildcard]
- see --zap
- --dump[=directory_path] [filename/wildcard]
- places output in directory specified, if none is specified
in the current directory (pwd). Compare --redirect
- -e [filename/wildcard]
- see --epub
- --epub [filename/wildcard]
- produces an epub document, [sisu version >=2
] (filename.epub). Alias -e
- --exc-*
- exclude output feature, overrides configuration settings
--exc-ocn, (exclude object citation numbering, (switches off object
citation numbering), affects html (seg, scroll), epub, xhtml, xml, pdf);
--exc-toc, (exclude table of contents, affects html (scroll), epub, pdf);
--exc-links-to-manifest, --exc-manifest-links, (exclude links to manifest,
affects html (seg, scroll)); --exc-search-form, (exclude search form,
affects html (seg, scroll), manifest); --exc-minitoc, (exclude mini table
of contents, affects html (seg), concordance, manifest);
--exc-manifest-minitoc, (exclude mini table of contents, affects
manifest); --exc-html-minitoc, (exclude mini table of contents, affects
html (seg), concordance); --exc-html-navigation, (exclude navigation,
affects html (seg)); --exc-html-navigation-bar, (exclude navigation bar,
affects html (seg)); --exc-html-search-form, (exclude search form, affects
html (seg, scroll)); --exc-html-right-pane, (exclude right pane/column,
affects html (seg, scroll)); --exc-html-top-band, (exclude top band,
affects html (seg, scroll), concordance (minitoc forced on to provide seg
navigation)); --exc-segsubtoc (exclude sub table of contents, affects html
(seg), epub); see also --inc-*
- -F [--webserv=webrick]
- see --sample-search-form
- -f [optional string part of filename]
- see --find
- --find [optional string part of filename]
- without match string, glob all .sst .ssm files in directory
(including language subdirectories). With match string, find files that
match given string in directory (including language subdirectories). Alias
-f, --glob, -G
- -G [optional string part of filename]
- see --find
- -g [filename/wildcard]
- see --git
- --git [filename/wildcard]
- produces or updates markup source file structure in a git
repo (experimental and subject to change). Alias -g
- --glob [optional string part of filename]
- see --find
- -h [filename/wildcard]
- see --html
- --harvest *.ss[tm]
- makes two lists of sisu output based on the sisu markup
documents in a directory: list of author and authors works (year and
titles), and; list by topic with titles and author. Makes use of header
metadata fields (author, title, date, topic_register). Can be used with
maintenance (-M) and remote placement (-R) flags.
- --help [topic]
- provides help on the selected topic, where topics
(keywords) include: list, (com)mands, short(cuts), (mod)ifiers,
(env)ironment, markup, syntax, headers, headings, endnotes, tables,
example, customise, skin, (dir)ectories, path, (lang)uage, db, install,
setup, (conf)igure, convert, termsheet, search, sql, features, license.
- --html [filename/wildcard]
- produces html output, segmented text with table of contents
(toc.html and index.html) and the document in a single file (scroll.html).
Alias -h
- -I [filename/wildcard]
- see --texinfo
- -i [filename/wildcard]
- see --manpage
- --inc-*
- include output feature, overrides configuration settings,
(usually the default if none set), has precedence over --exc-* (exclude
output feature). Some detail provided under --exc-*, see --exc-*
- -j [filename/wildcard]
- copies images associated with a file for use by html, xhtml
& xml outputs (automatically invoked by --dump & redirect).
- --keep-processing-files [filename/wildcard/url]
- see --maintenance
- -L
- prints license information.
- -M [filename/wildcard/url]
- see --maintenance
- -m [filename/wildcard/url]
- see --dal (document abstraction level/layer)
- --machine [filename/wildcard/url]
- see --dal (document abstraction level/layer)
- --maintenance [filename/wildcard/url]
- maintenance mode, interim processing files are preserved
and their locations indicated. (also see -V). Aliases -M and
--keep-processing-files.
- --manpage [filename/wildcard]
- produces man page of file, not suitable for all outputs.
Alias -i
- -N [filename/wildcard/url]
- document digest or document content certificate ( DCC ) as
md5 digest tree of the document: the digest for the document, and digests
for each object contained within the document (together with information
on software versions that produced it) (digest.txt). -NV for verbose
digest output to screen.
- -n [filename/wildcard/url]
- skip the creation of intermediate processing files
(document abstraction) if they already exist, this skips the equivalent of
-m which is otherwise assumed by most processing flags.
- --no-*
- see --exc-*
- -o [filename/wildcard/url]
- see --odt
- --odf [filename/wildcard/url]
- see --odt
- --odt [filename/wildcard/url]
- output basic document in opendocument file format
(opendocument.odt). Alias -o
- --output-by-*
- select output directory structure from 3 alternatives:
--output-by-language, (language directory (based on language code) with
filetype (html, epub, pdf etc.) subdirectories); --output-by-filetype,
(filetype directories with language code as part of filename);
--output-by-filename, (filename directories with language code as part of
filename). This is configurable. Alias --by-*
- -P [language_directory/filename language_directory]
- see --po4a
- -p [filename/wildcard]
- see --pdf
- --pdf [filename/wildcard]
- produces LaTeX pdf (portrait.pdf & landscape.pdf).
Default paper size is set in config file, or document header, or provided
with additional command line parameter, e.g. --papersize-a4 preset sizes
include: 'A4', U.S. 'letter' and
- --pg [instruction] [filename]
- database postgresql ( --pgsql may be used instead) possible
instructions, include: --createdb; --create; --dropall; --import
[filename]; --update [filename]; --remove [filename]; see database section
below. Alias -D
- --po [language_directory/filename language_directory]
- see --po4a
- --po4a [language_directory/filename language_directory]
- produces .pot and po files for the file in the languages
specified by the language directory. SiSU markup is placed in
subdirectories named with the language code, e.g. en/ fr/ es/. The sisu
config file must set the output directory structure to multilingual. v3,
experimental
- -Q [filename/wildcard]
- see --qrcode
- -q [filename/wildcard]
- see --quiet
- --qrcode [filename/wildcard]
- generate QR code image of metadata (used in manifest). v3
only.
- --quiet [filename/wildcard]
- quiet less output to screen.
- -R [filename/wildcard]
- see --rsync
- -r [filename/wildcard]
- see --scp
- --redirect[=directory_path] [filename/wildcard]
- places output in subdirectory under specified directory,
subdirectory uses the filename (without the suffix). If no output
directory is specified places the subdirectory under the current directory
(pwd). Compare --dump
- --rsync [filename/wildcard]
- copies sisu output files to remote host using rsync. This
requires that sisurc.yml has been provided with information on hostname
and username, and that you have your "keys" and ssh agent in
place. Note the behavior of rsync different if -R is used with other flags
from if used alone. Alone the rsync --delete parameter is sent, useful for
cleaning the remote directory (when -R is used together with other flags,
it is not). Also see --scp. Alias -R
- -S
- see --sisupod
- -S [filename/wildcard]
- see --sisupod
- -s [filename/wildcard]
- see --source
- --sample-search-form [--webserv=webrick]
- generate examples of (naive) cgi search form for sqlite and
pgsql depends on your already having used sisu to populate an sqlite
and/or pgsql database, (the sqlite version scans the output directories
for existing sisu_sqlite databases, so it is first necessary to create
them, before generating the search form) see -d -D and the database
section below. If the optional parameter --webserv=webrick is passed, the
cgi examples created will be set up to use the default port set for use by
the webrick server, (otherwise the port is left blank and the system
setting used, usually 80). The samples are dumped in the present work
directory which must be writable, (with screen instructions given that
they be copied to the cgi-bin directory). Alias -F
- --scp [filename/wildcard]
- copies sisu output files to remote host using scp. This
requires that sisurc.yml has been provided with information on hostname
and username, and that you have your "keys" and ssh agent in
place. Also see --rsync. Alias -r
- --sqlite --[instruction] [filename]
- database type set to sqlite, this produces one of two
possible databases, without additional database related instructions it
produces a discreet sqlite file for the document processed; with
additional instructions it produces a common sqlite database of all
processed documents that (come from the same document preparation
directory and as a result) share the same output directory base path
(possible instructions include: --createdb; --create; --dropall; --import
[filename]; --update [filename]; --remove [filename]); see database
section below. Alias -d
- --sisupod
- produces a sisupod a zipped sisu directory of markup files
including sisu markup source files and the directories local configuration
file, images and skins. Note: this only includes the configuration files
or skins contained in
./_sisu not those in ~/.sisu -S [filename/wildcard] option. Note: (this option is tested only with zsh). Alias -S
- --sisupod [filename/wildcard]
- produces a zipped file of the prepared document specified
along with associated images, by default named sisupod.zip they may
alternatively be named with the filename extension .ssp This provides a
quick way of gathering the relevant parts of a sisu document which can
then for example be emailed. A sisupod includes sisu markup source file,
(along with associated documents if a master file, or available in
multilingual versions), together with related images and skin. SiSU
commands can be run directly against a sisupod contained in a local
directory, or provided as a url on a remote site. As there is a security
issue with skins provided by other users, they are not applied unless the
flag --trust or --trusted is added to the command instruction, it is
recommended that file that are not your own are treated as untrusted. The
directory structure of the unzipped file is understood by sisu, and sisu
commands can be run within it. Note: if you wish to send multiple files,
it quickly becomes more space efficient to zip the sisu markup directory,
rather than the individual files for sending). See the -S option without
[filename/wildcard]. Alias -S
- --source [filename/wildcard]
- copies sisu markup file to output directory. Alias -s
- -T [filename/wildcard (*.termsheet.rb)]
- standard form document builder, preprocessing feature
- -t [filename/wildcard]
- see --txt
- --texinfo [filename/wildcard]
- produces texinfo and info file, (view with pinfo). Alias -I
- --txt [filename/wildcard]
- produces plaintext with Unix linefeeds and without markup,
(object numbers are omitted), has footnotes at end of each paragraph that
contains them [ -A for equivalent dos (linefeed)
output file] [see -e for endnotes]. (Options
include: --endnotes for endnotes --footnotes for footnotes at the end of
each paragraph --unix for unix linefeed (default) --msdos for msdos
linefeed). Alias -t
- -U [filename/wildcard]
- see --urls
- -u [filename/wildcard]
- provides url mapping of output files for the flags
requested for processing, also see -U
- --urls [filename/wildcard]
- prints url output list/map for the available processing
flags options and resulting files that could be requested, (can be used to
get a list of processing options in relation to a file, together with
information on the output that would be produced), -u provides url output
mapping for those flags requested for processing. The default assumes
sisu_webrick is running and provides webrick url mappings where
appropriate, but these can be switched to file system paths in sisurc.yml.
Alias -U
- -V
- on its own, provides SiSU version and environment
information (sisu --help env)
- -V [filename/wildcard]
- even more verbose than the -v flag.
- -v
- on its own, provides SiSU version information
- -v [filename/wildcard]
- see --verbose
- --v2 [filename/wildcard]
- invokes the sisu v2 document parser/generator. This is the
default and is normally omitted.
- --v3 [filename/wildcard]
- invokes the sisu v3 document parser/generator. Currently
under development and incomplete, v3 requires >= ruby1.9.2p180. You may
run sisu3 instead.
- --verbose [filename/wildcard]
- provides verbose output of what is being generated, where
output is placed (and error messages if any), as with -u flag provides a
url mapping of files created for each of the processing flag requests.
Alias -v
- -W
- see --webrick
- -w [filename/wildcard]
- see --concordance
- --webrick
- starts ruby's webrick webserver points at sisu output
directories, the default port is set to 8081 and can be changed in the
resource configuration files. [tip: the webrick server
requires link suffixes, so html output
should be created using the -h
option rather than -H ; also, note
-F webrick ]. Alias -W
- --wordmap [filename/wildcard]
- see --concordance
- --xhtml [filename/wildcard]
- produces xhtml/XML output for browser viewing (sax
parsing). Alias -b
- --xml-dom [filename/wildcard]
- produces XML output with deep document structure, in the
nature of dom. Alias -X
- --xml-sax [filename/wildcard]
- produces XML output shallow structure (sax parsing). Alias
-x
- -X [filename/wildcard]
- see --xml-dom
- -x [filename/wildcard]
- see --xml-sax
- -Y [filename/wildcard]
- produces a short sitemap entry for the document, based on
html output and the sisu_manifest. --sitemaps generates/updates the
sitemap index of existing sitemaps. (Experimental, [g,y,m
announcement this week])
- -y [filename/wildcard]
- produces an html summary of output generated (hyperlinked
to content) and document specific metadata (sisu_manifest.html). This step
is assumed for most processing flags.
- -Z [filename/wildcard]
- see --zap
- --zap [filename/wildcard]
- Zap, if used with other processing flags deletes output
files of the type about to be processed, prior to processing. If -Z is
used as the lone processing related flag (or in conjunction with a
combination of -[mMvVq]), will remove the related document output
directory. Alias -Z
3. COMMAND LINE MODIFIERS¶
- --no-ocn
- [with --html --pdf or --epub]
switches off object citation numbering. Produce output without identifying
numbers in margins of html or LaTeX/pdf output.
- --no-annotate
- strips output text of editor endnotes[^*1] denoted by
asterisk or dagger/plus sign
- --no-asterisk
- strips output text of editor endnotes[^*2] denoted by
asterisk sign
- --no-dagger
- strips output text of editor endnotes[^+1] denoted by
dagger/plus sign
4. DATABASE COMMANDS¶
dbi - database interface- --pg -v --createall
- initial step, creates required relations (tables, indexes)
in existing postgresql database (a database should be created manually and
given the same name as working directory, as requested) (rb.dbi) [
-dv --createall sqlite equivalent] it may be necessary
to run sisu -Dv --createdb initially NOTE: at the present time for
postgresql it may be necessary to manually create the database. The
command would be 'createdb [database name]' where database name
would be SiSU_[present working directory name (without
path)]. Please use only alphanumerics and underscores.
- --pg -v --import
- [filename/wildcard] imports data specified to postgresql db
(rb.dbi) [ -dv --import sqlite equivalent]
- --pg -v --update
- [filename/wildcard] updates/imports specified data to
postgresql db (rb.dbi) [ -dv --update sqlite
equivalent]
- --pg --remove
- [filename/wildcard] removes specified data to postgresql db
(rb.dbi) [ -d --remove sqlite equivalent]
- --pg --dropall
- kills data" and drops (postgresql or sqlite) db,
tables & indexes [ -d --dropall sqlite equivalent]
5. SHORTCUTS, SHORTHAND FOR MULTIPLE FLAGS¶
- --update [filename/wildcard]
- Checks existing file output and runs the flags required to
update this output. This means that if only html and pdf output was
requested on previous runs, only the -hp files will be applied, and only
these will be generated this time, together with the summary. This can be
very convenient, if you offer different outputs of different files, and
just want to do the same again.
- -0 to -5 [filename or wildcard]
- Default shorthand mappings (for v3, note that the defaults
can be changed/configured in the sisurc.yml file):
- -0
- -NQhewpotbxXyYv [this is the default
action run when no options are give,
i.e. on 'sisu [filename]']
- -1
- -Qhewpoty
- -2
- -NQhewpotbxXy
- -3
- -NQhewpotbxXyY
- -4
- -NQhewpotbxXDyY --update
- -5
- -NQhewpotbxXDyYv --update
5.1 COMMAND LINE WITH FLAGS - BATCH PROCESSING¶
In the data directory run sisu -mh filename or wildcard eg. "sisu -h cisg.sst" or "sisu -h *.{sst,ssm}" to produce html version of all documents.6. HELP¶
6.1 SISU MANUAL¶
The most up to date information on sisu should be contained in the sisu_manual, available at:<http://sisudoc.org/sisu/sisu_manual/>
./data/doc/sisu/markup-samples/sisu_manual
/usr/share/doc/sisu/markup-samples/sisu_manual
sisu sisu_manual.ssm
6.2 SISU MAN PAGES¶
If SiSU is installed on your system usual man commands should be available, try:man sisu
./data/doc/sisu/markup-samples/sisu_manual
/usr/share/doc/sisu/markup-samples/sisu_manual
/usr/share/doc/sisu/html/
./data/doc/sisu/html
6.3 SISU BUILT-IN INTERACTIVE HELP¶
This is particularly useful for getting the current sisu setup/environment information:sisu --help
sisu --help [subject]
sisu --help commands
sisu --help markup
sisu --help env [for feedback on the way your system is setup with regard to sisu]
sisu -V [environment information, same as above command]
sisu (on its own provides version and some help information)
7. INTRODUCTION TO SISU MARKUP[^10]¶
7.1 SUMMARY¶
SiSU source documents are plaintext (UTF-8)[^11] files* heading levels defines document structure
* text basic attributes, italics, bold etc.
* grouped text (objects), which are to be treated differently, such as code
blocks or poems.
* footnotes/endnotes
* linked text and images
* paragraph actions, such as indent, bulleted, numbered-lists, etc.
sisu --identify [filename].sst
sisu --query-history
sisu --query-0.38
7.2 MARKUP EXAMPLES¶
7.2.1 ONLINE¶
Online markup examples are available together with the respective outputs produced from <http://www.jus.uio.no/sisu/SiSU/examples.html> or from <http://www.jus.uio.no/sisu/sisu_examples/>7.2.2 INSTALLED¶
With SiSU installed sample skins may be found in: /usr/share/doc/sisu/markup-samples (or equivalent directory) and if sisu-markup-samples is installed also under: /usr/share/doc/sisu/markup-samples-non-free8. MARKUP OF HEADERS¶
Headers contain either: semantic meta-data about a document, which can be used by any output module of the program, or; processing instructions.% this would be a comment
8.1 SAMPLE HEADER¶
This current document is loaded by a master document that has a header similar to this one:% SiSU master 2.0 @title: SiSU :subtitle: Manual @creator: :author: Amissah, Ralph @publisher: [publisher name] @rights: Copyright (C) Ralph Amissah 2007, License GPL 3 @classify: :type: information :topic_register: SiSU:manual;electronic documents:SiSU:manual :subject: ebook, epublishing, electronic book, electronic publishing, electronic document, electronic citation, data structure, citation systems, search % used_by: manual @date: :published: 2008-05-22 :created: 2002-08-28 :issued: 2002-08-28 :available: 2002-08-28 :modified: 2010-03-03 @make: :num_top: 1 :breaks: new=C; break=1 :skin: skin_sisu_manual :bold: /Gnu|Debian|Ruby|SiSU/ :manpage: name=sisu - documents: markup, structuring, publishing in multiple standard formats, and search; synopsis=sisu [-abcDdeFhIiMmNnopqRrSsTtUuVvwXxYyZz0-9] [filename/wildcard ] . sisu [-Ddcv] [instruction] . sisu [-CcFLSVvW] . sisu --v2 [operations] . sisu --v3 [operations] @links: { SiSU Homepage }http://www.sisudoc.org/ { SiSU Manual }http://www.sisudoc.org/sisu/sisu_manual/ { Book Samples & Markup Examples }http://www.jus.uio.no/sisu/SiSU/examples.html { SiSU Download }http://www.jus.uio.no/sisu/SiSU/download.html { SiSU Changelog }http://www.jus.uio.no/sisu/SiSU/changelog.html { SiSU Git repo }http://git.sisudoc.org/?p=code/sisu.git;a=summary { SiSU List Archives }http://lists.sisudoc.org/pipermail/sisu/ { SiSU @ Debian }http://packages.qa.debian.org/s/sisu.html { SiSU Project @ Debian }http://qa.debian.org/developer.php?login=sisu@lists.sisudoc.org { SiSU @ Wikipedia }http://en.wikipedia.org/wiki/SiSU
8.2 AVAILABLE HEADERS¶
Header tags appear at the beginning of a document and provide meta information on the document (such as the Dublin Core), or information as to how the document as a whole is to be processed. All header instructions take the form @headername: or on the next line and indented by once space :subheadername: All Dublin Core meta tags are available% SiSU 2.0 [declared file-type identifier with markup version]
@title: [title text] [this header is the only one that is mandatory] :subtitle: [subtitle if any] :language: English
@creator: :author: [Lastname, First names] :illustrator: [Lastname, First names] :translator: [Lastname, First names] :prepared_by: [Lastname, First names]
@date: :published: [year or yyyy-mm-dd] :created: [year or yyyy-mm-dd] :issued: [year or yyyy-mm-dd] :available: [year or yyyy-mm-dd] :modified: [year or yyyy-mm-dd] :valid: [year or yyyy-mm-dd] :added_to_site: [year or yyyy-mm-dd] :translated: [year or yyyy-mm-dd]
@rights: :copyright: Copyright (C) [Year and Holder] :license: [Use License granted] :text: [Year and Holder] :translation: [Name, Year] :illustrations: [Name, Year]
@classify: :topic_register: SiSU:markup sample:book;book:novel:fantasy :type: :subject: :description: :keywords: :abstract: :isbn: [ISBN] :loc: [Library of Congress classification] :dewey: [Dewey classification] :pg: [Project Gutenberg text number]
@links: { SiSU }http://www.sisudoc.org { FSF }http://www.fsf.org
@make: :skin: skin_name [skins change default settings related to the appearance of documents generated] :num_top: 1 :headings: [text to match for each level (e.g. PART; Chapter; Section; Article; or another: none; BOOK|FIRST|SECOND; none; CHAPTER;) :breaks: new=:C; break=1 :promo: sisu, ruby, sisu_search_libre, open_society :bold: [regular expression of words/phrases to be made bold] :italics: [regular expression of words/phrases to italicise]
@original: :language: [language]
@notes: :comment: :prefix: [prefix is placed just after table of contents]
9. MARKUP OF SUBSTANTIVE TEXT¶
9.1 HEADING LEVELS¶
Heading levels are :A~ ,:B~ ,:C~ ,1~ ,2~ ,3~ ... :A - :C being part / section headings, followed by other heading levels, and 1 -6 being headings followed by substantive text or sub-headings. :A~ usually the title :A~? conditional level 1 heading (used where a stand-alone document may be imported into another)1~filename level 1 heading, % the primary division such as Chapter that is followed by substantive text, % and may be further subdivided (this is the level on which by default html % segments are made)
9.2 FONT ATTRIBUTES¶
markup example:normal text, *{emphasis}*, !{bold text}!, /{italics}/, _{underscore}_, "{citation}", ^{superscript}^, ,{subscript},, +{inserted text}+, -{strikethrough}-, #{monospace}# normal text*{emphasis}* [note: can be configured to be represented by bold, italics or underscore]!{bold text}!_{underscore}_/{italics}/"{citation}"^{superscript}^,{subscript},+{inserted text}+-{strikethrough}-#{monospace}#
9.3 INDENTATION AND BULLETS¶
markup example:ordinary paragraph_1 indent paragraph one step_2 indent paragraph two steps_9 indent paragraph nine steps
indent paragraph one step
indent paragraph two steps
indent paragraph nine steps
_* bullet text_1* bullet text, first indent_2* bullet text, two step indent
* bullet text, first indent
* bullet text, two step indent
# numbered list numbered list 1., 2., 3, etc._# numbered list numbered list indented a., b., c., d., etc.
9.4 HANGING INDENTS¶
markup example:_0_1 first line no indent, rest of paragraph indented one step _1_0 first line indented, rest of paragraph no indent in each case level may be 0-9
first line no indent, rest of paragraph indented one step
9.5 FOOTNOTES / ENDNOTES¶
Footnotes and endnotes are marked up at the location where they would be indicated within a text. They are automatically numbered. The output type determines whether footnotes or endnotes will be produced~{ a footnote or endnote }~
normal text~{ self contained endnote marker & endnote in one }~ continues
normal text ~{* unnumbered asterisk footnote/endnote, insert multiple asterisks if required }~ continuesnormal text ~{** another unnumbered asterisk footnote/endnote }~ continues
normal text ~[* editors notes, numbered asterisk footnote/endnote series ]~ continuesnormal text ~[+ editors notes, numbered asterisk footnote/endnote series ]~ continues
% note the endnote marker "~^" normal text~^ continues^~ endnote text following the paragraph in which the marker occurs
9.6 LINKS¶
9.6.1 NAKED URLS WITHIN TEXT, DEALING WITH URLS¶
urls found within text are marked up automatically. A url within text is automatically hyperlinked to itself and by default decorated with angled braces, unless they are contained within a code block (in which case they are passed as normal text), or escaped by a preceding underscore (in which case the decoration is omitted).normal text http://www.sisudoc.org/ continues
normal text _http://www.sisudoc.org/ continues deb _http://www.jus.uio.no/sisu/archive unstable main non-free
deb http://www.jus.uio.no/sisu/archive unstable main non-freedeb-src http://www.jus.uio.no/sisu/archive unstable main non-free
9.6.2 LINKING TEXT¶
To link text or an image to a url the markup is as followsabout { SiSU }http://url.org markup
about {~^ SiSU }http://url.org markup
{ tux.png 64x80 }image% various url linked images{tux.png 64x80 "a better way" }http://www.sisudoc.org/{GnuDebianLinuxRubyBetterWay.png 100x101 "Way Better - with Gnu/Linux, Debian and Ruby" }http://www.sisudoc.org/{~^ ruby_logo.png "Ruby" }http://www.ruby-lang.org/en/markup example: { tux.png 64x80 }image % various url linked images {tux.png 64x80 "a better way" }http://www.sisudoc.org/ {GnuDebianLinuxRubyBetterWay.png 100x101 "Way Better - with Gnu/Linux, Debian and Ruby" }http://www.sisudoc.org/ {~^ ruby_logo.png "Ruby" }http://www.ruby-lang.org/en/
{~^ [text to link] }http://url.org % maps to: { [text to link] }http://url.org ~{ http://url.org }~ % which produces hyper-linked text within a document/paragraph, % with an endnote providing the url for the text location used in the hyperlink
text marker *~name
9.7 GROUPED TEXT¶
9.7.1 TABLES¶
Tables may be prepared in two either of two formstable{ c3; 40; 30; 30; This is a table this would become column two of row one column three of row one is here And here begins another row column two of row two column three of row two, and so on }table
[table omitted, see other document formats]
!_ Table 3.1: Contributors to Wikipedia, January 2001 - June 2005 {table~h 24; 12; 12; 12; 12; 12; 12;} |Jan. 2001|Jan. 2002|Jan. 2003|Jan. 2004|July 2004|June 2006 Contributors* | 10| 472| 2,188| 9,653| 25,011| 48,721 Active contributors** | 9| 212| 846| 3,228| 8,442| 16,945 Very active contributors*** | 0| 31| 190| 692| 1,639| 3,016 No. of English language articles| 25| 16,000| 101,000| 190,000| 320,000| 630,000 No. of articles, all languages | 25| 19,000| 138,000| 490,000| 862,000|1,600,000 * Contributed at least ten times; ** at least 5 times in last month; *** more than 100 times in last month.
[table omitted, see other document formats]
9.7.2 POEM¶
basic markup:poem{ Your poem here }poem Each verse in a poem is given an object number.
poem{ `Fury said to a mouse, That he met in the house, "Let us both go to law: I will prosecute YOU. --Come, I'll take no denial; We must have a trial: For really this morning I've nothing to do." Said the mouse to the cur, "Such a trial, dear Sir, With no jury or judge, would be wasting our breath." "I'll be judge, I'll be jury," Said cunning old Fury: "I'll try the whole cause, and condemn you to death."' }poem
`Fury said to a
mouse, That he
met in the
house,
"Let us
both go to
law: I will
prosecute
YOU. --Come,
I'll take no
denial; We
must have a
trial: For
really this
morning I've
nothing
to do."
Said the
mouse to the
cur, "Such
a trial,
dear Sir,
With
no jury
or judge,
would be
wasting
our
breath."
"I'll be
judge, I'll
be jury,"
Said
cunning
old Fury:
"I'll
try the
whole
cause,
and
condemn
you
to
death."'
9.7.3 GROUP¶
basic markup:group{Your grouped text here}groupA group is treated as an object and given a single object number.
group{ 'Fury said to a mouse, That he met in the house, "Let us both go to law: I will prosecute YOU. --Come, I'll take no denial; We must have a trial: For really this morning I've nothing to do." Said the mouse to the cur, "Such a trial, dear Sir, With no jury or judge, would be wasting our breath." "I'll be judge, I'll be jury," Said cunning old Fury: "I'll try the whole cause, and condemn you to death."' }group
`Fury said to a
mouse, That he
met in the
house,
"Let us
both go to
law: I will
prosecute
YOU. --Come,
I'll take no
denial; We
must have a
trial: For
really this
morning I've
nothing
to do."
Said the
mouse to the
cur, "Such
a trial,
dear Sir,
With
no jury
or judge,
would be
wasting
our
breath."
"I'll be
judge, I'll
be jury,"
Said
cunning
old Fury:
"I'll
try the
whole
cause,
and
condemn
you
to
death."'
9.7.4 CODE¶
Code tags code{ ... }code (used as with other group tags described above) are used to escape regular sisu markup, and have been used extensively within this document to provide examples of SiSU markup. You cannot however use code tags to escape code tags. They are however used in the same way as group or poem tags.`Fury said to a mouse, That he met in the house, "Let us both go to law: I will prosecute YOU. --Come, I'll take no denial; We must have a trial: For really this morning I've nothing to do." Said the mouse to the cur, "Such a trial, dear Sir, With no jury or judge, would be wasting our breath." "I'll be judge, I'll be jury," Said cunning old Fury: "I'll try the whole cause, and condemn you to death."'
1 | `Fury said to a 2 | mouse, That he 3 | met in the 4 | house, 5 | "Let us 6 | both go to 7 | law: I will 8 | prosecute 9 | YOU. --Come, 10 | I'll take no 11 | denial; We 12 | must have a 13 | trial: For 14 | really this 15 | morning I've 16 | nothing 17 | to do." 18 | Said the 19 | mouse to the 20 | cur, "Such 21 | a trial, 22 | dear Sir, 23 | With 24 | no jury 25 | or judge, 26 | would be 27 | wasting 28 | our 29 | breath." 30 | "I'll be 31 | judge, I'll 32 | be jury," 33 | Said 34 | cunning 35 | old Fury: 36 | "I'll 37 | try the 38 | whole 39 | cause, 40 | and 41 | condemn 42 | you 43 | to 44 | death."'
9.8 ADDITIONAL BREAKS - LINEBREAKS WITHIN OBJECTS, COLUMN AND PAGE-BREAKS¶
9.8.1 LINE-BREAKS¶
To break a line within a "paragraph object", two backslashes \\ with a space before and a space or newline after them may be used.To break a line within a "paragraph object", two backslashes \\ with a space before and a space or newline after them \\ may be used.
9.8.2 PAGE BREAKS¶
Page breaks are only relevant and honored in some output formats. A page break or a new page may be inserted manually using the following markup on a line on its own:<:pb>
<:pn>
9.9 BOOK INDEX¶
To make an index append to paragraph the book index term relates to it, using an equal sign and curly braces.Paragraph containing main term and sub-term. ={Main term:sub-term}
Main term, 1 sub-term, 1
Paragraph containing main term, second term and sub-term. ={first term; second term: sub-term}
First term, 1, Second term, 1, sub-term, 1
Paragraph containing main term, second term and sub-term. ={Main term:sub-term+1|second sub-term} A paragraph that continues discussion of the first sub-term
Main term, 1, sub-term, 1-3, second sub-term, 1,
10. COMPOSITE DOCUMENTS MARKUP¶
It is possible to build a document by creating a master document that requires other documents. The documents required may be complete documents that could be generated independently, or they could be markup snippets, prepared so as to be easily available to be placed within another text. If the calling document is a master document (built from other documents), it should be named with the suffix .ssm Within this document you would provide information on the other documents that should be included within the text. These may be other documents that would be processed in a regular way, or markup bits prepared only for inclusion within a master document .sst regular markup file, or .ssi (insert/information) A secondary file of the composite document is built prior to processing with the same prefix and the suffix ._sst<< filename1.sst << filename2.ssi
<< filename.ssi <<{filename.ssi} % using textlink alternatives << |filename.ssi|@|^|
11. MARKUP SYNTAX HISTORY¶
11.1 NOTES RELATED TO FILES-TYPES AND MARKUP SYNTAX¶
2.0 introduced new headers and is therefore incompatible with 1.0 though otherwise the same with the addition of a couple of tags (i.e. a superset)@title: :subtitle: @creator: :author: :translator: :illustrator: @rights: :text: :illustrations:
#{ this enclosed text would be monospaced }#
/^={.+?}$/
={GNU/Linux community distribution:Debian+2|Fedora|Gentoo;Free Software Foundation+5}
Free Software Foundation, 1-6 GNU/Linux community distribution, 1 Debian, 1-3 Fedora, 1 Gentoo,
/[:;]{.+?}[:;][a-z+]/
:A~ @title by @author
.B SiSU 0.52
% SiSU 0.38
~{* for example for describing an author }~ and ~{** for describing a second author }~
~[* my note ]~ or ~[+ another note ]~
@headername: and headers :A~ :B~ :C~ 1~ 2~ 3~
0~headername and headers 1~ 2~ 3~ 4~ 5~ 6~
.ssm and .ssi to replace .s1 .s2 .s3 .r1 .r2 .r3 and .si
rename 's/\.s[123]$/\.sst/' *.s{1,2,3} rename 's/\.r[123]$/\.ssm/' *.r{1,2,3} rename 's/\.si$/\.ssi/' *.si
12. SISU FILETYPES¶
SiSU has plaintext and binary filetypes, and can process either type of document.12.1 .SST .SSM .SSI MARKED UP PLAIN TEXT¶
SiSU documents are prepared as plain-text (utf-8) files with SiSU markup. They may make reference to and contain images (for example), which are stored in the directory beneath them _sisu/image. SiSU plaintext markup files are of three types that may be distinguished by the file extension used: regular text .sst; master documents, composite documents that incorporate other text, which can be any regular text or text insert; and inserts the contents of which are like regular text except these are marked.ssi and are not processed.
sisu -s [filename]
12.1.1 SISU TEXT - REGULAR FILES (.SST)¶
The most common form of document in SiSU, see the section on SiSU markup.12.1.2 SISU MASTER FILES (.SSM)¶
Composite documents which incorporate other SiSU documents which may be either regular SiSU text .sst which may be generated independently, or inserts prepared solely for the purpose of being incorporated into one or more master documents.12.1.3 SISU INSERT FILES (.SSI)¶
Inserts are documents prepared solely for the purpose of being incorporated into one or more master documents. They resemble regular SiSU text files except they are ignored by the SiSU processor. Making a file a .ssi file is a quick and convenient way of flagging that it is not intended that the file should be processed on its own.12.2 SISUPOD, ZIPPED BINARY CONTAINER (SISUPOD.ZIP, .SSP)¶
A sisupod is a zipped SiSU text file or set of SiSU text files and any associated images that they contain (this will be extended to include sound and multimedia-files)sisu -S [filename]
sisu -S
13. EXPERIMENTAL ALTERNATIVE INPUT REPRESENTATIONS¶
13.1 ALTERNATIVE XML¶
SiSU offers alternative XML input representations of documents as a proof of concept, experimental feature. They are however not strictly maintained, and incomplete and should be handled with care.sisu --to-sax [filename/wildcard] or sisu --to-sxs [filename/wildcard]
sisu --to-dom [filename/wildcard] or sisu --to-sxd [filename/wildcard]
sisu --to-node [filename/wildcard] or sisu --to-sxn [filename/wildcard]
sisu --from-xml2sst [filename/wildcard [.sxs.xml,.sxd.xml,sxn.xml]]
sisu --from-sxml [filename/wildcard [.sxs.xml,.sxd.xml,sxn.xml]]
13.1.1 XML SAX REPRESENTATION¶
To convert from sst to simple xml (sax) representation:sisu --to-sax [filename/wildcard] or sisu --to-sxs [filename/wildcard]
sisu --from-xml2sst [filename/wildcard [.sxs.xml,.sxd.xml,sxn.xml]]
sisu --from-sxml [filename/wildcard [.sxs.xml,.sxd.xml,sxn.xml]]
13.1.2 XML DOM REPRESENTATION¶
To convert from sst to simple xml (dom) representation:sisu --to-dom [filename/wildcard] or sisu --to-sxd [filename/wildcard]
sisu --from-xml2sst [filename/wildcard [.sxs.xml,.sxd.xml,sxn.xml]]
sisu --from-sxml [filename/wildcard [.sxs.xml,.sxd.xml,sxn.xml]]
13.1.3 XML NODE REPRESENTATION¶
To convert from sst to simple xml (node) representation:sisu --to-node [filename/wildcard] or sisu --to-sxn [filename/wildcard]
sisu --from-xml2sst [filename/wildcard [.sxs.xml,.sxd.xml,sxn.xml]]
sisu --from-sxml [filename/wildcard [.sxs.xml,.sxd.xml,sxn.xml]]
14. CONFIGURATION¶
14.1 DETERMINING THE CURRENT CONFIGURATION¶
Information on the current configuration of SiSU should be available with the help command:sisu -v
sisu --help env
14.2 CONFIGURATION FILES (CONFIG.YML)¶
SiSU configration parameters are adjusted in the configuration file, which can be used to override the defaults set. This includes such things as which directory interim processing should be done in and where the generated output should be placed../_sisu/sisurc.yml
~/.sisu/sisurc.yml
/etc/sisu/sisurc.yml
15. SKINS¶
Skins modify the default appearance of document output on a document, directory, or site wide basis. Skins are looked for in the following locations:./_sisu/skin
~/.sisu/skin
/etc/sisu/skin
./skin/doc
./skin/dir
./skin/site
15.1 DOCUMENT SKIN¶
Documents take on a document skin, if the header of the document specifies a skin to be used.@skin: skin_united_nations
15.2 DIRECTORY SKIN¶
A directory may be mapped on to a particular skin, so all documents within that directory take on a particular appearance. If a skin exists in the skin/dir with the same name as the document directory, it will automatically be used for each of the documents in that directory, (except where a document specifies the use of another skin, in the skin/doc directory).15.3 SITE SKIN¶
A site skin, modifies the program default skin.15.4 SAMPLE SKINS¶
With SiSU installed sample skins may be found in:/etc/sisu/skin/doc and
/usr/share/doc/sisu/markup-samples/samples/_sisu/skin/doc
/usr/share/doc/sisu/markup-samples-non-free/samples/_sisu/skin/doc
/usr/share/doc/sisu/markup-samples-non-free/samples/_sisu/skin/yml (or
equivalent directory)
16. CSS - CASCADING STYLE SHEETS (FOR HTML, XHTML AND XML)¶
CSS files to modify the appearance of SiSU html, XHTML or XML may be placed in the configuration directory: ./_sisu/css; ~/.sisu/css or; /etc/sisu/css and these will be copied to the output directories with the command sisu -CC.17. ORGANISING CONTENT - DIRECTORY STRUCTURE AND MAPPING¶
SiSU v3 has new options for the source directory tree, and output directory structures of which there are 3 alternatives.17.1 DOCUMENT SOURCE DIRECTORY¶
The document source directory is the directory in which sisu processing commands are given. It contains the sisu source files (.sst .ssm .ssi), or (for sisu v3 may contain) subdirectories with language codes which contain the sisu source files, so all English files would go in subdirectory en/, French in fr/, Spanish in es/ and so on. ISO 639-1 codes are used (as varied by po4a). A list of available languages (and possible sub-directory names) can be obtained with the command "sisu --help lang" The list of languages is limited to langagues supported by XeTeX polyglosia.17.1.1 GENERAL DIRECTORIES¶
% files stored at this level e.g. sisu_manual.sst or % for sisu v3 may be under language sub-directories % e.g. % configuration file e.g. sisurc.yml % skins in various skin directories doc, dir, site, yml
17.2 DOCUMENT OUTPUT DIRECTORY STRUCTURES¶
17.2.1 OUTPUT DIRECTORY ROOT¶
The output directory root can be set in the sisurc.yml file. Under the root, subdirectories are made for each directory in which a document set resides. If you have a directory named poems or conventions, that directory will be created under the output directory root and the output for all documents contained in the directory of a particular name will be generated to subdirectories beneath that directory (poem or conventions). A document will be placed in a subdirectory of the same name as the document with the filetype identifier stripped (.sst .ssm)17.2.2 ALTERNATIVE OUTPUT STRUCTURES¶
There are 3 possibile output structures described as being, by language, by filetype or by filename, the selection is made in sisurc.yml#% output_dir_structure_by: language; filetype; or filename output_dir_structure_by: language #(language & filetype, preferred?) #output_dir_structure_by: filetype #output_dir_structure_by: filename #(default, closest to original v1 & v2)
17.2.3 BY LANGUAGE¶
The by language directory structure places output files|-- en |-- epub |-- hashes |-- html | |-- viral_spiral.david_bollier | |-- manifest | |-- qrcode | |-- odt | |-- pdf | |-- sitemaps | |-- txt | |-- xhtml | `-- xml |-- po4a | `-- live-manual | |-- po | |-- fr | `-- pot `-- _sisu |-- css |-- image |-- image_sys -> ../../_sisu/image_sys `-- xml |-- rnc |-- rng `-- xsd
17.2.4 BY FILETYPE¶
The by filetype directory structure separates output files by filetype, all html files in one directory pdfs in another and so on. Filenames are given a language extension.|-- epub |-- hashes |-- html |-- viral_spiral.david_bollier |-- manifest |-- qrcode |-- odt |-- pdf |-- po4a |-- live-manual | |-- po | |-- fr | `-- pot |-- _sisu | |-- css | |-- image | |-- image_sys -> ../../_sisu/image_sys | `-- xml | |-- rnc | |-- rng | `-- xsd |-- sitemaps |-- txt |-- xhtml `-- xml
17.2.5 BY FILENAME¶
The by filename directory structure places most output of a particular file (the different filetypes) in a common directory.|-- epub |-- po4a |-- live-manual | |-- po | |-- fr | `-- pot |-- _sisu | |-- css | |-- image | |-- image_sys -> ../../_sisu/image_sys | `-- xml | |-- rnc | |-- rng | `-- xsd |-- sitemaps |-- src |-- pod `-- viral_spiral.david_bollier
17.2.6 REMOTE DIRECTORIES¶
% containing sub_directories named after the generated files from which they are made ./subject_name/src % contains shared source files text and binary e.g. sisu_manual.sst and sisu_manual.sst.zip ./subject_name/_sisu % configuration file e.g. sisurc.yml ./subject_name/_sisu/skin % skins in various skin directories doc, dir, site, yml ./subject_name/_sisu/css ./subject_name/_sisu/image % images for documents contained in this directory ./subject_name/_sisu/mm
17.2.7 SISUPOD¶
% files stored at this level e.g. sisu_manual.sst ./sisupod/_sisu % configuration file e.g. sisurc.yml ./sisupod/_sisu/skin % skins in various skin directories doc, dir, site, yml ./sisupod/_sisu/css ./sisupod/_sisu/image % images for documents contained in this directory ./sisupod/_sisu/mm
17.3 ORGANISING CONTENT¶
18. HOMEPAGES¶
SiSU is about the ability to auto-generate documents. Home pages are regarded as custom built items, and are not created by SiSU. More accurately, SiSU has a default home page, which will not be appropriate for use with other sites, and the means to provide your own home page instead in one of two ways as part of a site's configuration, these being:18.1 HOME PAGE AND OTHER CUSTOM BUILT PAGES IN A SUB-DIRECTORY¶
Custom built pages, including the home page index.html may be placed within the configuration directory _sisu/home/ in any of the locations that is searched for the configuration directory, namely ./_sisu ; ~/_sisu ; /etc/sisu From there they are copied to the root of the output directory with the command:sisu -CC
18.2 HOME PAGE WITHIN A SKIN¶
Skins are described in a separate section, but basically are a file written in the programming language Ruby that may be provided to change the defaults that are provided with sisu with respect to individual documents, a directories contents or for a site.class Home def homepage # place the html content of your homepage here, this will become index.html <<HOME <html> <head></head> <doc> <p>this is my new homepage.</p> </doc> </html> HOME end end
19. MARKUP AND OUTPUT EXAMPLES¶
19.1 MARKUP EXAMPLES¶
Current markup examples and document output samples are provided at <http://www.jus.uio.no/sisu/SiSU/examples.html>20. SISU SEARCH - INTRODUCTION¶
SiSU output can easily and conveniently be indexed by a number of standalone indexing tools, such as Lucene, Hyperestraier.21. SQL¶
21.1 POPULATING SQL TYPE DATABASES¶
SiSU feeds sisu markupd documents into sql type databases PostgreSQL[^20] and/or SQLite[^21] database together with information related to document structure.* one containing semantic (and other) headers, including, title, author,
subject, (the Dublin Core...);
* another the substantive texts by individual "paragraph" (or object) -
along with structural information, each paragraph being identifiable by its
paragraph number (if it has one which almost all of them do), and the
substantive text of each paragraph quite naturally being searchable (both in
formatted and clean text versions for searching); and
* a third containing endnotes cross-referenced back to the paragraph from
which they are referenced (both in formatted and clean text versions for
searching).
* a fourth table with a one to one relation with the headers table contains
full text versions of output, eg. pdf, html, xml, and ascii.
22. POSTGRESQL¶
22.1 NAME¶
SiSU - Structured information, Serialized Units - a document publishing system, postgresql dependency package22.2 DESCRIPTION¶
Information related to using postgresql with sisu (and related to the sisu_postgresql dependency package, which is a dummy package to install dependencies needed for SiSU to populate a postgresql database, this being part of SiSU - man sisu).22.3 SYNOPSIS¶
sisu -D [instruction] [filename/wildcard if required]
sisu -D --pg --[instruction] [filename/wildcard if required]
22.4 COMMANDS¶
Mappings to two databases are provided by default, postgresql and sqlite, the same commands are used within sisu to construct and populate databases however -d (lowercase) denotes sqlite and -D (uppercase) denotes postgresql, alternatively --sqlite or --pgsql may be used22.4.1 CREATE AND DESTROY DATABASE¶
- --pgsql --createall
- initial step, creates required relations (tables, indexes)
in existing (postgresql) database (a database should be created manually
and given the same name as working directory, as requested) (rb.dbi)
- sisu -D --createdb
- creates database where no database existed before
- sisu -D --create
- creates database tables where no database tables existed
before
- sisu -D --Dropall
- destroys database (including all its content)! kills data
and drops tables, indexes and database associated with a given directory
(and directories of the same name).
- sisu -D --recreate
- destroys existing database and builds a new empty database
structure
22.4.2 IMPORT AND REMOVE DOCUMENTS¶
- sisu -D --import -v [filename/wildcard]
- populates database with the contents of the file. Imports
documents(s) specified to a postgresql database (at an object level).
- sisu -D --update -v [filename/wildcard]
- updates file contents in database
- sisu -D --remove -v [filename/wildcard]
- removes specified document from postgresql database.
23. SQLITE¶
23.1 NAME¶
SiSU - Structured information, Serialized Units - a document publishing system.23.2 DESCRIPTION¶
Information related to using sqlite with sisu (and related to the sisu_sqlite dependency package, which is a dummy package to install dependencies needed for SiSU to populate an sqlite database, this being part of SiSU - man sisu).23.3 SYNOPSIS¶
sisu -d [instruction] [filename/wildcard if required]
sisu -d --(sqlite|pg) --[instruction] [filename/wildcard if required]
23.4 COMMANDS¶
Mappings to two databases are provided by default, postgresql and sqlite, the same commands are used within sisu to construct and populate databases however -d (lowercase) denotes sqlite and -D (uppercase) denotes postgresql, alternatively --sqlite or --pgsql may be used23.4.1 CREATE AND DESTROY DATABASE¶
- --sqlite --createall
- initial step, creates required relations (tables, indexes)
in existing (sqlite) database (a database should be created manually and
given the same name as working directory, as requested) (rb.dbi)
- sisu -d --createdb
- creates database where no database existed before
- sisu -d --create
- creates database tables where no database tables existed
before
- sisu -d --dropall
- destroys database (including all its content)! kills data
and drops tables, indexes and database associated with a given directory
(and directories of the same name).
- sisu -d --recreate
- destroys existing database and builds a new empty database
structure
23.4.2 IMPORT AND REMOVE DOCUMENTS¶
- sisu -d --import -v [filename/wildcard]
- populates database with the contents of the file. Imports
documents(s) specified to an sqlite database (at an object level).
- sisu -d --update -v [filename/wildcard]
- updates file contents in database
- sisu -d --remove -v [filename/wildcard]
- removes specified document from sqlite database.
24. INTRODUCTION¶
24.1 SEARCH - DATABASE FRONTEND SAMPLE, UTILISING DATABASE AND SISU FEATURES,¶
INCLUDING OBJECT CITATION NUMBERING (BACKEND CURRENTLY POSTGRESQL)- sisu -F --webserv-webrick
- builds a cgi web search frontend for the database created
sisu --help sqlPostgresql user: ralph current db set: SiSU_sisu port: 5432 dbi connect: DBI:Pg:database=SiSU_sisu;port=5432 sqlite current db set: /home/ralph/sisu_www/sisu/sisu_sqlite.db dbi connect DBI:SQLite:/home/ralph/sisu_www/sisu/sisu_sqlite.db
24.2 SEARCH FORM¶
- sisu -F
- generates a sample search form, which must be copied to the
web-server cgi directory
- sisu -F --webserv-webrick
- generates a sample search form for use with the webrick
server, which must be copied to the web-server cgi directory
- sisu -Fv
- as above, and provides some information on setting up
hyperestraier
- sisu -W
- starts the webrick server which should be available
wherever sisu is properly installed
25. SISU_WEBRICK¶
25.1 NAME¶
SiSU - Structured information, Serialized Units - a document publishing system25.2 SYNOPSIS¶
sisu_webrick [port]25.3 DESCRIPTION¶
sisu_webrick is part of SiSU (man sisu) sisu_webrick starts Ruby SiSU output is written, providing a list of these directories (assuming SiSU is in use and they exist).25.4 SUMMARY OF MAN PAGE¶
sisu_webrick, may be started on it's own with the command: sisu_webrick [port] or using the sisu command with the -W flag: sisu -W [port]25.5 DOCUMENT PROCESSING COMMAND FLAGS¶
sisu -W [port] starts Ruby Webrick web-server, serving SiSU output directories, on the port provided, or if no port is provided and the defaults have not been changed in ~/.sisu/sisurc.yaml then on port 808125.6 FURTHER INFORMATION¶
For more information on SiSU see: <http://www.sisudoc.org/> or <http://www.jus.uio.no/sisu>25.7 AUTHOR¶
Ralph Amissah <ralph@amissah.com> or <ralph.amissah@gmail.com>25.8 SEE ALSO¶
sisu(1)
sisu_vim(7)
26. REMOTE SOURCE DOCUMENTS¶
SiSU processing instructions can be run against remote source documents by providing the url of the documents against which the processing instructions are to be carried out. The remote SiSU documents can either be sisu marked up files in plaintext .sst or .ssm or; zipped sisu files, sisupod.zip or filename.sspsisu -3 http://[provide url to valid .sst or .ssm file]
.sst for the desired document.
sisu -3 http://[provide url to valid sisupod.zip or .ssp file]
REMOTE DOCUMENT OUTPUT¶
27. REMOTE OUTPUT¶
Once properly configured SiSU output can be automatically posted once generated to a designated remote machine using either rsync, or scp.sisu -3R sisu_remote.sst
27.1 COMMANDS¶
- -R [filename/wildcard]
- copies sisu output files to remote host using rsync. This
requires that sisurc.yml has been provided with information on hostname
and username, and that you have your "keys" and ssh agent in
place. Note the behavior of rsync different if -R is used with other flags
from if used alone. Alone the rsync --delete parameter is sent, useful for
cleaning the remote directory (when -R is used together with other flags,
it is not). Also see -r
- -r [filename/wildcard]
- copies sisu output files to remote host using scp. This
requires that sisurc.yml has been provided with information on hostname
and username, and that you have your "keys" and ssh agent in
place. Also see -R
27.2 CONFIGURATION¶
[expand on the setting up of an ssh-agent / keychain]28. REMOTE SERVERS¶
As SiSU is generally operated using the command line, and works within a Unix type environment, SiSU the program and all documents can just as easily be on a remote server, to which you are logged on using a terminal, and commands and operations would be pretty much the same as they would be on your local machine.29. QUICKSTART - GETTING STARTED HOWTO¶
29.1 INSTALLATION¶
Installation is currently most straightforward and tested on the Debian platform, as there are packages for the installation of sisu and all requirements for what it does.29.1.1 DEBIAN INSTALLATION¶
SiSU is available directly from the Debian Sid and testing archives (and possibly Ubuntu), assuming your /etc/apt/sources.list is set accordingly:aptitude update aptitude install sisu-complete
#/etc/apt/sources.listdeb http://ftp.fi.debian.org/debian/ unstable main non-free contribdeb-src http://ftp.fi.debian.org/debian/ unstable main non-free contrib
aptitude updateaptitude install sisu-complete sisu-markup-samples
#/etc/apt/sources.list deb http://www.jus.uio.no/sisu/archive unstable main non-free deb-src http://www.jus.uio.no/sisu/archive unstable main non-free
aptitude update aptitude install sisu-complete sisu-markup-samples
29.1.2 RPM INSTALLATION¶
RPMs are provided though untested, they are prepared by running alien against the source package, and against the debs.<http://www.jus.uio.no/sisu/SiSU/download.html#rpm>
rpm -i [rpm package name]
29.1.3 INSTALLATION FROM SOURCE¶
To install SiSU from source check information at:<http://www.jus.uio.no/sisu/SiSU/download.html#current>
ruby setup.rb config ruby setup.rb setup #[and as root:] ruby setup.rb install
<http://i.loveruby.net/en/projects/setup/>
<http://i.loveruby.net/en/projects/setup/doc/usage.html>
ruby install base
ruby install
ruby install base
<http://make.rubyforge.org/>
<http://rubyforge.org/frs/?group_id=615>
ruby install help
ruby install -T
29.2 TESTING SISU, GENERATING OUTPUT¶
To check which version of sisu is installed:29.2.1 BASIC TEXT, PLAINTEXT, HTML, XML, ODF, EPUB¶
Having moved to the directory that contains the markup samples (see instructions above if necessary), choose a file and run sisu against it29.2.2 LATEX / PDF¶
Assuming a LaTeX engine such as tetex or texlive is installed with the required modules (done automatically on selection of sisu-pdf in Debian )29.2.3 RELATIONAL DATABASE - POSTGRESQL, SQLITE¶
Relational databases need some setting up - you must have permission to create the database and write to it when you run sisu.29.3 GETTING HELP¶
29.3.1 THE MAN PAGES¶
Type:man sisu
29.3.2 BUILT IN HELP¶
sisu --help29.3.3 THE HOME PAGE¶
<http://www.sisudoc.org/>29.4 MARKUP SAMPLES¶
A number of markup samples (along with output) are available off:30. EDITOR FILES, SYNTAX HIGHLIGHTING¶
The directory:./data/sisu/v2/conf/editor-syntax-etc/
./data/sisu/v3/conf/editor-syntax-etc/
/usr/share/sisu/v2/conf/editor-syntax-etc
/usr/share/sisu/v3/conf/editor-syntax-etc
package: sisu-vim
there is a vim syntax highlighting and folds component
file: sisu.lang
/usr/share/gtksourceview-1.0/language-specs
~/.gnome2/gtksourceview-1.0/language-specs
status: very basic syntax highlighting
comments: this editor features display line wrap and is used by Goby!
file: nanorc
~/.nanorc
status: basic syntax highlighting
comments: assumes dark background; no display line-wrap; does line breaks
~/.diakonos/diakonos.conf
status: basic syntax highlighting
file: sisu.xml
place in:
/usr/share/apps/katepart/syntax
or
~/.kde/share/apps/katepart/syntax
[settings::configure kate::{highlighting,filetypes}]
[tools::highlighting::{markup,scripts}:: .B SiSU ]
file: sisu_nedit.pats
nedit -import sisu_nedit.pats
status: a very clumsy first attempt [not really done]
comments: this editor features display line wrap
files: sisu-mode.el
to file ~/.emacs add the following 2 lines:
(add-to-list 'load-path
"/usr/share/sisu/v2/conf/editor-syntax-etc/emacs")
(require 'sisu-mode.el)
[not done / not yet included]
files:
package is the most comprehensive sisu syntax highlighting and editor
environment provided to date (is for vim/ gvim, and is separate from the
contents of this directory)
status: this includes: syntax highlighting; vim folds; some error checking
comments: this editor features display line wrap
31. HOW DOES SISU WORK?¶
SiSU markup is fairly minimalistic, it consists of: a (largely optional) document header, made up of information about the document (such as when it was published, who authored it, and granting what rights) and any processing instructions; and markup within the substantive text of the document, which is related to document structure and typeface. SiSU must be able to discern the structure of a document, (text headings and their levels in relation to each other), either from information provided in the document header or from markup within the text (or from a combination of both). Processing is done against an abstraction of the document comprising of information on the document's structure and its objects,[2] which the program serializes (providing the object numbers) and which are assigned hash sum values based on their content. This abstraction of information about document structure, objects, (and hash sums), provides considerable flexibility in representing documents different ways and for different purposes (e.g. search, document layout, publishing, content certification, concordance etc.), and makes it possible to take advantage of some of the strengths of established ways of representing documents, (or indeed to create new ones).32. SUMMARY OF FEATURES¶
* sparse/minimal markup (clean utf-8 source texts). Documents are prepared in a single UTF-8 file using a minimalistic mnemonic syntax. Typical literature, documents like "War and Peace" require almost no markup, and most of the headers are optional.* html - both as a single scrollable text and a segmented document
* xhtml
* epub
* XML - both in sax and dom style xml structures for further development as
required
* ODF - open document format, the iso standard for document storage
* LaTeX - used to generate pdf
* pdf (via LaTeX)
* sql - population of an sql database, (at the same object level that is
used to cite text within a document)
33. HELP SOURCES¶
33.1 MAN PAGES¶
man sisu
man sisu-concordance
man sisu-epub
man sisu-git
man sisu-harvest
man sisu-html
man sisu-odf
man sisu-pdf
man sisu-pg
man sisu-po
man sisu-sqlite
man sisu-txt
man 7 sisu_complete
man 7 sisu_pdf
man 7 sisu_postgresql
man 7 sisu_sqlite
man sisu_termsheet
man sisu_webrick
33.2 SISU GENERATED OUTPUT - LINKS TO HTML¶
Note SiSU documentation is prepared in SiSU and output is available in multiple formats including amongst others html, pdf, odf and epub, which may be also be accessed via the html pages[^30]33.2.1 WWW.SISUDOC.ORG¶
<http://sisudoc.org/sisu/sisu_manual/index.html><http://sisudoc.org/sisu/sisu_manual/index.html>
33.3 MAN2HTML¶
33.3.1 LOCALLY INSTALLED¶
file:///usr/share/doc/sisu/html/sisu.1.htmlfile:///usr/share/doc/sisu/html/sisu.1.html
/usr/share/doc/sisu/html/sisu_pdf.7.html
/usr/share/doc/sisu/html/sisu_postgresql.7.html
/usr/share/doc/sisu/html/sisu_sqlite.7.html
/usr/share/doc/sisu/html/sisu_webrick.1.html
33.3.2 WWW.JUS.UIO.NO/SISU¶
<http://www.jus.uio.no/sisu/man/sisu.1.html><http://www.jus.uio.no/sisu/man/sisu.1.html>
<http://www.jus.uio.no/sisu/man/sisu_complete.7.html>
<http://www.jus.uio.no/sisu/man/sisu_pdf.7.html>
<http://www.jus.uio.no/sisu/man/sisu_postgresql.7.html>
<http://www.jus.uio.no/sisu/man/sisu_sqlite.7.html>
<http://www.jus.uio.no/sisu/man/sisu_webrick.1.html>
- 1.
- objects include: headings, paragraphs, verse, tables,
images, but not footnotes/endnotes which are numbered separately and tied
to the object from which they are referenced.
- 2.
- i.e. the html, pdf, epub, odf outputs are each built
individually and optimised for that form of presentation, rather than for
example the html being a saved version of the odf, or the pdf being a
saved version of the html.
- 3.
- the different heading levels
- 4.
- units of text, primarily paragraphs and headings, also any
tables, poems, code-blocks
- 5.
- Specification submitted by Adobe to ISO to become a full
open ISO specification
- 6.
- ISO standard ISO/IEC 26300:2006
- 7.
- An open standard format for e-books
- *1.
- square brackets
- *2.
- square brackets
- +1.
- square brackets
- 10.
- From sometime after SiSU 0.58 it should be possible to
describe SiSU markup using SiSU, which though not an original design goal
is useful.
- 11.
- files should be prepared using UTF-8 character encoding
- 12.
- a footnote or endnote
- 13.
- self contained endnote marker & endnote in one
- *.
- unnumbered asterisk footnote/endnote, insert multiple
asterisks if required
- **.
- another unnumbered asterisk footnote/endnote
- *3.
- editors notes, numbered asterisk footnote/endnote series
- +2.
- editors notes, numbered asterisk footnote/endnote series
- 14.
- <http://www.sisudoc.org/>
- 17.
- Table from the Wealth of Networks by Yochai Benkler
- 18.
- is not a regular file to be worked on, and thus less likely
that people will have "accidents", working on a .ssc file that
is overwritten by subsequent processing. It may be however that when the
resulting file is shared .ssc is an appropriate suffix to use.
- 20.
- <http://www.postgresql.org/>
- 23.
- (which could be extended further with current back-end). As
regards scaling of the database, it is as scalable as the database (here
Postgresql) and hardware allow.
- 24.
- of this feature when demonstrated to an IBM software
innovations evaluator in 2004 he said to paraphrase: this could be of
interest to us. We have large document management systems, you can search
hundreds of thousands of documents and we can tell you which documents
meet your search criteria, but there is no way we can tell you without
opening each document where within each your matches are found.
- 25.
- There is nothing to stop MySQL support being added in
future.
- 28.
- <http://www.jus.uio.no/sisu/man>
SEE ALSO¶
sisu(1),HOMEPAGE¶
More information about SiSU can be found at <http://www.sisudoc.org/> or < http://www.jus.uio.no/sisu/>.AUTHOR¶
SiSU is written by Ralph Amissah <ralph@amissah.com>.2012-05-25 | 3.2.10 |