App-Chronicle

 view release on metacpan or  search on metacpan

bin/chronicle  view on Meta::CPAN


=item Finding Blog Posts.

By default C<data/*.txt> are read, but you may adjust the input directory via the C<--input> command-line flag.  The pattern may be set with C<--pattern>.

B<NOTE> The pattern is applied recursively, if you wish to create sub-directories with your posts inside them for organizational purposes.

=item Inserting them into the SQLite database.

The header is read to look for things such as the post-date, the subject,
and the tags.  The body is imported literally, unless expanded and reformatted
via a plugin.

=item Executing plugins

Each registered plugin will be invoked in turn, allowing the various
output parts to be generated.

=back

The output is exclusively generated by the plugins bundled with the

bin/chronicle  view on Meta::CPAN

=over 8

=item L<Chronicle::Plugin::Markdown>

=item L<Chronicle::Plugin::MultiMarkdown>

=item L<Chronicle::Plugin::Textile>

=back

Beyond format conversion this method is also good for expanding macros, or snippets of HTML.  (This is done by L<Chronicle::Plugin::YouTube> for example.)

=item on_initiate

This is called prior to any generation, with a reference to the configuration
options and the database handle used for storage.

=item on_generate

This is called to generate the output pages.  There is no logical difference between this method and C<on_initiate> except that the former plugin methods are guaranteed to have been called prior to C<on_generate> being invoked.

lib/Chronicle/Config/Reader.pm  view on Meta::CPAN

=over 8

=item Comment Handling

Comments are begun with the C<#> character and continue to the end of the line.

Comments may occur at the start, middle, or end of a line.

=item Environmental variable expansion

Environmental variables are expanded if they are detected.

=item Command-execution and expansion

If backticks are found in configuration values they will be replaced with the output of the specified command.

=back

The following snippet demonstrates these features:

=for example begin

lib/Chronicle/Plugin/Snippets/Meta.pm  view on Meta::CPAN

    if ( $ENV{ 'USER' } )
    {

        #
        #  Set the username
        #
        $Chronicle::GLOBAL_TEMPLATE_VARS{ "build_username" } = $ENV{ 'USER' };


        #
        #  If we can expand that into a full-name then do so
        #
        my ( $name,    $passwd, $uid, $gid,   $quota,
             $comment, $gcos,   $dir, $shell, $expire )
          = getpwnam( $ENV{ 'USER' } );

        #
        #  Did we get a GCOS field?  If so strip the trailing "," and
        # set if it is non-empty
        #
        if ($gcos)

lib/Chronicle/Plugin/Snippets/Meta.pm  view on Meta::CPAN

    {

        #
        #  If not we'll look for a hostname via the Sys::Hostname module.
        #
        $hostname = Sys::Hostname::hostname();

        #
        #  The previous line will have probably returned a short-name.
        #
        #  Try to expand it into FQDN.  If that fails - well at least we tried.
        #
        my @values = ( gethostbyname($hostname) );
        if ( scalar @values )
        {
            $hostname = $values[0];
        }
    }

    if ($hostname)
    {

lib/Chronicle/Plugin/YouTube.pm  view on Meta::CPAN


=head1 NAME

Chronicle::Plugin::YouTube - Allow Youtube videos to be embedded.

=head1 DESCRIPTION

This plugin allows simple markup to be expanded into inline YouTube
videos.  The tag "youtube" will also be automatically applied to
the appropriate entries.

For example the following blog-post will contain an inline video:

=for example begin

    Title: My Title
    Date: 10th March 2015

themes/bs2/static/js/html5shiv.js  view on Meta::CPAN


  /** Used to skip problem elements */
  var reSkip = /^<|^(?:button|map|select|textarea|object|iframe|option|optgroup)$/i;

  /** Not all elements can be cloned in IE **/
  var saveClones = /^(?:a|b|code|div|fieldset|h1|h2|h3|h4|h5|h6|i|label|li|ol|p|q|span|strong|style|table|tbody|td|th|tr|ul)$/i;

  /** Detect whether the browser supports default html5 styles */
  var supportsHtml5Styles;

  /** Name of the expando, to work with multiple documents or to re-shiv one document */
  var expando = '_html5shiv';

  /** The id for the the documents expando */
  var expanID = 0;

  /** Cached data for each document */
  var expandoData = {};

  /** Detect whether the browser supports unknown elements */
  var supportsUnknownElements;

  (function() {
    try {
        var a = document.createElement('a');
        a.innerHTML = '<xyz></xyz>';
        //if the hidden property is implemented we can assume, that the browser supports basic HTML5 Styles
        supportsHtml5Styles = ('hidden' in a);

themes/bs2/static/js/html5shiv.js  view on Meta::CPAN

    return typeof elements == 'string' ? elements.split(' ') : elements;
  }
  
    /**
   * Returns the data associated to the given document
   * @private
   * @param {Document} ownerDocument The document.
   * @returns {Object} An object of data.
   */
  function getExpandoData(ownerDocument) {
    var data = expandoData[ownerDocument[expando]];
    if (!data) {
        data = {};
        expanID++;
        ownerDocument[expando] = expanID;
        expandoData[expanID] = data;
    }
    return data;
  }

  /**
   * returns a shived element for the given nodeName and document
   * @memberOf html5
   * @param {String} nodeName name of the element
   * @param {Document} ownerDocument The context document.
   * @returns {Object} The shived element.

themes/bs2/static/js/jquery-1.7.1.min.js  view on Meta::CPAN

/*! jQuery v1.7.1 jquery.com | jquery.org/license */
(function(a,b){function cy(a){return f.isWindow(a)?a:a.nodeType===9?a.defaultView||a.parentWindow:!1}function cv(a){if(!ck[a]){var b=c.body,d=f("<"+a+">").appendTo(b),e=d.css("display");d.remove();if(e==="none"||e===""){cl||(cl=c.createElement("ifram...
f.event={add:function(a,c,d,e,g){var h,i,j,k,l,m,n,o,p,q,r,s;if(!(a.nodeType===3||a.nodeType===8||!c||!d||!(h=f._data(a)))){d.handler&&(p=d,d=p.handler),d.guid||(d.guid=f.guid++),j=h.events,j||(h.events=j={}),i=h.handle,i||(h.handle=i=function(a){ret...
{for(var a=0,b;(b=this[a])!=null;a++){b.nodeType===1&&f.cleanData(b.getElementsByTagName("*"));while(b.firstChild)b.removeChild(b.firstChild)}return this},clone:function(a,b){a=a==null?!1:a,b=b==null?a:b;return this.map(function(){return f.clone(this...



( run in 2.112 seconds using v1.01-cache-2.11-cpan-97f6503c9c8 )