HiD - Static website publishing framework
HīD is a blog-aware, GitHub-friendly, static website generation system inspired by Jekyll.
HiD users probably want to look at the documentation for the hid command.
Subsequent documentation in this file describes internal details that are only useful or interesting for people that are trying to modify or extend HiD.
Categories hash, contains (category, post) pairs
Hashref of command line options to integrate into the config.
(HiD::App::Commands should pass in the $opt variable to this.)
$opt
Hashref of configuration information.
Path to a configuration file.
Hashref of standard configuration options. The default config is:
destination => '_site' , include_dir => '_includes', layout_dir => '_layouts' , plugin_dir => '_plugins' , posts_dir => '_posts' , source => '.' ,
Directory to write output files into.
N.B.: If it doesn't exist and is needed, it will be created.
String that distinguishes initial excerpt from "below the fold" content
Defaults to "\n\n"
Directory for template "include" files
Hashref of input files. Keys are file paths; values are what type of file the system has classified that path as.
Directory where template files are located.
Hashref of HiD::Layout objects, keyed by layout name.
If set, only this many blog post files will be processed during publishing.
Setting this can significantly speed up publishing for sites with many blog posts.
Array of objects (pages, posts, files) created during site processing.
Regular expression for identifying "page" files.
# FIXME should it be possible to set this from the config?
Arrayref of HiD::Page objects, populated during processing.
Directory for plugins, which will be called after publish.
Plugins, called after publish.
Regular expression for which files will be recognized as blog posts.
FIXME should this be configurable?
Directory where blog posts are located.
Arrayref of HiD::Post objects, populated during processing.
Slot to hold the HiD::Processor object that will be used during the publication process.
Arguments to use when instantiating the processor attribute.
Can be an arrayref or a hashref.
Defaults to appropriate Template Toolkit arguments.
ArrayRef of HiD::File objects, populated during processing.
Base directory that all other paths are calculated relative to.
Tags hash, contains (tag, posts) pairs
Hashref of files written out during the publishing process.
my $config_key_value = $self->get_config( $config_key_name );
Given a config key name, returns a config key value.
$self->add_input( $input_file => $input_type );
Record what input type a particular input file is.
if( $self->seen_input( $input_file )) { ... }
Check to see if a particular input file has been seen.
my $hid_layout_obj = $self->get_layout_by_name( $name );
Given a layout name (e.g., 'default') returns the corresponding HiD::Layout object.
$self->add_object( $generated_object );
Add an object to the set of objects generated during site processing.
my @objects = $self->all_objects;
Returns the list of all objects that have been generated.
$self->add_written_file( $file => 1 );
Record that a file was written.
my @files = $self->all_written_files;
Return the list of all files that were written out.
if( $self->wrote_file( $file )) { ... }
Check to see if a particular file has been written out.
$self->publish;
Process files and generate output per the active configuration.
ChinaXing
reyjrar
jekyll
Papery
StaticVolt
version 1.0
John SJ Anderson <genehack@genehack.org>
This software is copyright (c) 2012 by John SJ Anderson.
This is free software; you can redistribute it and/or modify it under the same terms as the Perl 5 programming language system itself.
To install HiD, copy and paste the appropriate command in to your terminal.
cpanm
cpanm HiD
CPAN shell
perl -MCPAN -e shell install HiD
For more information on module installation, please visit the detailed CPAN module installation guide.