Expand description
ddoc is a markdown based static site generator.
Complete documentation at https://dystroy.org/ddoc
§Usage overview
Create a directory, then move to it
mkdir website & cd websiteInitialize the site:
ddoc --initThis creates:
- a
.gitignorefile, which eases inclusion of your site in a git managed project - a
ddoc.hjsonfile, holding the basic properties and navigation - a
srcfolder, for your markdown files, CSS style sheets and images - a
pluginsfolder, with default plugins
To build your site, run
ddocThis updates a site directory, whose content can be sent to your server.
To test it locally, run
ddoc --serveThen have a look at the documentation to improve your site.
Modules§
- before_
0_ 11 - This module ensures compatibility with configuration from versions 0.1 to 0.11
- before_
0_ 16
Structs§
- Args
- Launch arguments
- Cargo
Toml - Cargo
Toml Package - Config
- Element
- Element
Key - Element
List - A collection of elements, a vessel for deserializing
- Element
List Deserializer - Embedded
Plugin - Init
Values - Menu
- The settings for the insertion of a menu in a web page.
- Module
- Either the main project or a plugin
- NavLink
- A single link in the navigation bar
- Page
- Page
List - Page
Path - Page
Writer - Project
- A ddoc project, with its configuration, pages, and location which allows building it.
- Server
- Sourced
- Static
Entry - Implicit reference to one of the files in
/src/jsor/src/css - Toc
- The settings for the insertion of a table of content in a web page.
- Watch
Target - Something that should be watched for changes to trigger a rebuild of the project
Enums§
- Attribute
Value - The value of an attribute in a ddoc element (
ddoc-link,ddoc-menu, etc). - DdError
- Element
Content - Element
Type - File
Change - List
Item - NavLink
Part - Text
Constants§
Statics§
Functions§
- compare_
versions - copy_
normal_ recursive - Copy normal non hidden files from
src_dirtodst_dirrecursively - duration_
since - escape_
attr - escape_
hjson_ string - escape_
text - find_
file_ ignore_ case - fix_
old_ config - For support of old ddoc versions (<= 0.11), convert old nav components
if the new
bodyfield is empty - init_
ddoc_ project - init_
hjson_ in_ dir - Initialize a ddoc.hjson file in the specified directory (do nothing if one already exists)
- init_
src_ in_ dir - Create and fill the
src/directory in the givendir. - is_
current_ version_ older_ than - plugin_
is_ known - project_
subdirectory - Search direct subdirectories of
parentfor a ddoc project (a directory containing a validddoc.hjsonfile). - read_
file - Deserialize an object from a JSON, TOML, or HJSON file.
- rebuild_
on_ change - watch for file changes to keep a project up to date
- resource_
file_ bytes - Get the bytes of a file from the plugin name and the path starting from its src/ directory (e.g. “css/main.css”)
- run
- Run the ddoc command line application