(((meta (@ (content . "Structure of Zettelstore") (name . "title"))) (meta (@ (content . "manual") (name . "role"))) (meta (@ (content . "#design #manual #zettelstore") (name . "tags"))) (meta (@ (content . "zmk") (name . "syntax"))) (meta (@ (content . "00001000000000") (name . "back"))) (meta (@ (content . "00001000000000 00001006050000") (name . "backward"))) (meta (@ (content . "1") (name . "box-number"))) (meta (@ (content . "(c) 2020-present by Detlef Stern ") (name . "copyright"))) (meta (@ (content . "20210126175322") (name . "created"))) (meta (@ (content . "00000000020001 00000000040001 00001002000000 00001004010000 00001004020000 00001005090000 00001006050000 00001012000000 00001012053200 00001014000000") (name . "forward"))) (meta (@ (content . "en") (name . "lang"))) (meta (@ (content . "EUPL-1.2-or-later") (name . "license"))) (meta (@ (content . "20241213101751") (name . "modified"))) (meta (@ (content . "20241213101751") (name . "published"))) (meta (@ (content . "public") (name . "visibility")))) (p "Zettelstore is a software that manages your zettel." " " "Since every zettel must be readable without any special tool, most zettel has to be stored as ordinary files within specific directories." " " "Typically, file names and file content must comply to specific rules so that Zettelstore can manage them." " " "If you add, delete, or change zettel files with other tools, e.g. a text editor, Zettelstore will monitor these actions.") (p "Zettelstore provides additional services to the user." " " "Via the builtin " (a (@ (href . "00001014000000")) "web user interface") " you can work with zettel in various ways." " " "For example, you are able to list zettel, to create new zettel, to edit them, or to delete them." " " "You can view zettel details and relations between zettel.") (p "In addition, Zettelstore provides an " (@L (@H "“") "application programming interface" (@H "”")) " (" (a (@ (href . "00001012000000")) "API") ") that allows other software to communicate with the Zettelstore." " " "Zettelstore becomes extensible by external software." " " "For example, a more sophisticated user interface could be built, or an application for your mobile device that allows you to send content to your Zettelstore as new zettel.") (h2 (@ (id . "where-zettel-are-stored")) "Where zettel are stored") (p "Your zettel are stored typically as files in a specific directory." " " "If you have not explicitly specified the directory, a default directory will be used." " " "The directory has to be specified at " (a (@ (href . "00001004010000")) "startup time") "." " " "Nested directories are not supported (yet).") (p "Every file in this directory that should be monitored by Zettelstore must have a file name that begins with 14 digits (0-9), the " (a (@ (href . "00001006050000")) "zettel identifier") "." " " "If you create a new zettel via the " (a (@ (href . "00001014000000")) "web user interface") " or via the " (a (@ (href . "00001012053200")) "API") ", the zettel identifier will be the timestamp of the current date and time (format is " (kbd "YYYYMMDDhhmmss") ")." " " "This allows zettel to be sorted naturally by creation time.") (p "Since the only restriction on zettel identifiers are the 14 digits, you are free to use other digit sequences." " " "The " (a (@ (href . "00001004020000")) "configuration zettel") " is one prominent example, as well as these manual zettel." " " "You can create these special zettel by manually renaming the underlying zettel files.") (p "It is allowed that the file name contains other characters after the 14 digits." " " "These are ignored by Zettelstore.") (p "Two filename extensions are used by Zettelstore:") (ol (li (kbd ".zettel") " is a format that stores metadata and content together in one file,") (li "the empty file extension is used, when the content must be stored in its own file, e.g. image data;" " " "in this case, the filename just the 14 digits of the zettel identifier, and optional characters except the period " (kbd "\".\"") ".")) (p "Other filename extensions are used to determine the " (@L (@H "“") "syntax" (@H "”")) " of a zettel." " " "This allows to use other content within the Zettelstore, e.g. images or HTML templates.") (p "For example, you want to store an important figure in the Zettelstore that is encoded as a " (kbd ".png") " file." " " "Since each zettel contains some metadata, e.g. the title of the figure, the question arises where these data should be stores." " " "The solution is a meta-file with the same zettel identifier, but without a filename extension." " " "Zettelstore recognizes this situation and reads in both files for the one zettel containing the figure." " " "It maintains this relationship as long as these files exists.") (p "In case of some textual zettel content you do not want to store the metadata and the zettel content in two different files." " " "Here the " (kbd ".zettel") " extension will signal that the metadata and the zettel content will be put in the same file, separated by an empty line or a line with three dashes (" (@L (@H "“") (kbd "---") (@H "”")) ", also known as " (@L (@H "“") "YAML separator" (@H "”")) ").") (h2 (@ (id . "predefined-zettel")) "Predefined zettel") (p "Zettelstore contains some " (a (@ (href . "00001005090000")) "predefined zettel") " to work properly." " " "The " (a (@ (href . "00001004020000")) "configuration zettel") " is one example." " " "To render the builtin " (a (@ (href . "00001014000000")) "web user interface") ", some templates are used, as well as a " (a (@ (href . "00000000020001")) "layout specification in CSS") "." " " "The icon that visualizes a broken image is a " (a (@ (href . "00000000040001")) "predefined GIF image") "." " " "All of these are visible to the Zettelstore as zettel.") (p "One reason for this is to allow you to modify these zettel to adapt Zettelstore to your needs and visual preferences.") (p "Where are these zettel stored?" " " "They are stored within the Zettelstore software itself, because one " (a (@ (href . "00001002000000")) "design goal") " was to have just one executable file to use Zettelstore." " " "But data stored within an executable program cannot be changed later" (sup (@ (id . "fnref:1")) (a (@ (class . "zs-noteref") (href . "#fn:1") (role . "doc-noteref")) "1")) ".") (p "To allow changing predefined zettel, both the file store and the internal zettel store are internally chained together." " " "If you change a zettel, it will be always stored as a file." " " "If a zettel is requested, Zettelstore will first try to read that zettel from a file." " " "If such a file was not found, the internal zettel store is searched secondly.") (p "Therefore, the file store " (@L (@H "“") "shadows" (@H "”")) " the internal zettel store." " " "If you want to read the original zettel, you have to delete the zettel (which removes it from the file directory)." " " "Now we have two places where zettel are stored: in the specific directory and within the Zettelstore software.") (ul (li (a (@ (href . "00001005090000")) "List of predefined zettel"))) (h2 (@ (id . "boxes-alternative-ways-to-store-zettel")) "Boxes: alternative ways to store zettel") (p "As described above, a zettel may be stored as a file inside a directory or inside the Zettelstore software itself." " " "Zettelstore allows other ways to store zettel by providing an abstraction called " (em "box") "." (sup (@ (id . "fnref:2")) (a (@ (class . "zs-noteref") (href . "#fn:2") (role . "doc-noteref")) "2"))) (p "A file directory which stores zettel is called a " (@L (@H "“") "directory box" (@H "”")) "." " " "But zettel may be also stored in a ZIP file, which is called " (@L (@H "“") "file box" (@H "”")) "." " " "For testing purposes, zettel may be stored in volatile memory (called " (em "RAM") ")." " " "This way is called " (@L (@H "“") "memory box" (@H "”")) ".") (p "Other types of boxes could be added to Zettelstore." " " "What about a " (@L (@H "“") "remote Zettelstore box" (@H "”")) "?"))