ZkInfos version 1.0

Nick James

2024-02-21

1 Introduction

ZkInfo is a command line interface to a sort of Zettelkasten system. It consists of nominally atomic pieces of tagged information, which can be recovered by querying for tags or words.

The program

1.1 Web Pages

The tags page shows a list of tags when you hover or click at top right. Select union or intersection to find info with any or all of the tags selected in the check boxes below.

The words page is a bit more complicated owing to the large number of words. Initially you see all infos with two buttons. the goto info button asks you for a number and shows that info, irrespective of any other choices.

The select button shows a union/intersection choice plus checkboxes for each word. Make your choices here, then click the view button to see the infos.

Both sets of checkboxes can be disabled by clicking the set words off button, which shows all infos, and enabled by clicking the set words on button, which appears when the checkboxes are disabled.

2 Installation

3 Synopsis

ZkInfos -h? -v? (-c <file>)? (-(r|u|d) <id>)?

options are:

    -c <value>          create info from <file>
    -create             create new infos.db in current directory
    -d <value>          delete <info number>
    -h                  this help
    -r <value>          read <info number>
    -t                  tag list
    -u <value>          update <info number>
    -v                  version
    -w                  word list - return infos with words matching all arguments
try ZkInfos.exe -w awk | less

4 Action

ZkInfos stores supposedly atomic information as text in a database. Individual pieces of information are addressed by their id in the database. A datum may contain references to other data points and may be tagged. References and tags are rendered as hyperlinks in the html page.

The program also maintains a searchable word list.

4.1 Special formatting

4.2 Access

The information is stored in an sqlite database called infos.db. ZkInfos.exe has to be started in this directory. Do ZkInfos -create to create the database if it doesn’t exist.

Create

ZkInfos.exe -c <filename> prompts to create an info from <filename> the contents of filename.

Read

ZkInfos.exe -r <number> prints info <number> to stdout.

Update

ZkInfos.exe -u <number> prints info <number> to zk<number>.txt and writes contents of zk<number>.txt to the database when you press <return>.

Delete

ZkInfos.exe -d <number> deletes info <number>.

ZkInfos.exe -w word {word} prints tags containing all words to stdout.

List tags

ZkInfos.exe -t lists all tags to stdout.

5 Programmer’s Notes

5.1 Command Line Interface

The crud commands are straightforward queries on the database.

5.2 Generated Html

In order to parse links and tags, the info table is written to a temporary file with fields and records separated by ascii unit- and record-separators.

temporary file format

Html is then generated from the ZkInfos structure.

6 Bugs

7 Colophon

Produced with:

pp ZkInfosHelp.txt | pandoc --self-contained --toc --toc-depth=2 -N -c devDoc.css -s -t html5 -o ZkInfosHelp.html

2024-02-21 01:22:14