Class: Nanoc3::DataSources::FilesystemVerbose

Inherits:
Nanoc3::DataSource show all
Includes:
Filesystem
Defined in:
lib/nanoc3/data_sources/filesystem_verbose.rb

Overview

The filesystem_verbose data source is the old data source for a new nanoc site. It stores all data as files on the hard disk.

None of the methods are documented in this file. See Nanoc3::DataSource for documentation on the overridden methods instead.

The filesystem_verbose data source stores its items and layouts in nested directories. Each directory represents a single item or layout. The root directory for items is the ‘content` directory; for layouts it is the `layouts` directory.

Every directory has a content file and a meta file. The content file contains the actual item content, while the meta file contains the item’s or the layout’s metadata, formatted as YAML.

Both content files and meta files are named after its parent directory (i.e. item). For example, an item/layout named ‘foo` will have a directory named `foo`, with e.g. a `foo.markdown` content file and a `foo.yaml` meta file.

Content file extensions are not used for determining the filter that should be run; the meta file defines the list of filters. The meta file extension must always be ‘.yaml`, though.

For backwards compatibility, content files can also have the ‘index` basename. Similarly, meta files can have the `meta` basename. For example, a parent directory named `foo` can have an `index.txt` content file and a `meta.yaml` meta file.

The identifier is calculated by stripping the extension; if there is more than one extension, only the last extension is stripped and the previous extensions will be part of the identifier.

Instance Attribute Summary

Attributes included from Filesystem

#vcs

Attributes inherited from Nanoc3::DataSource

#config, #items_root, #layouts_root

Method Summary

Methods included from Filesystem

#create_item, #create_layout, #down, #items, #layouts, #setup, #up

Methods inherited from Nanoc3::DataSource

#create_item, #create_layout, #down, #initialize, #items, #layouts, #loading, #setup, #unuse, #up, #update, #use

Methods included from PluginRegistry::PluginMethods

#identifier, #identifiers, #named, #register

Constructor Details

This class inherits a constructor from Nanoc3::DataSource