Sha256: c5a70189db947b134d12c35a4ae169df8ca97adf57bcfe5466a62eeb154135ac
Contents?: true
Size: 739 Bytes
Versions: 8
Compression:
Stored size: 739 Bytes
Contents
require 'webgen/sourcehandler/base' module Webgen::SourceHandler # Handles directory source paths. class Directory include Base # Creation of directory nodes is special because once they are created, they are only deleted # when the source path gets deleted. Otherwise, only the meta information of the node gets # updated. def create_node(parent, path) if node = node_exists?(parent, path) node.meta_info.clear node.meta_info.update(path.meta_info) node.dirty = true node else super(parent, path) end end # Return an empty string to signal that the directory should be written to the output. def content(node) '' end end end
Version data entries
8 entries across 8 versions & 2 rubygems