DESCRIPTION

This module stores configuration in a series of YAML files spread across a directory tree, and provides uniform access to the data structure.

It can load a single YAML file or a directory tree containing YAML files as leaves. The tree's branches can be returned as data structures or YAML documents, and the tree can be modified and rewritten. Directory-based branches can be collapsed back into files and file-based branches can be exploded into directories.

METHODS

$tree->load_file($filename)

This method loads the given filename as YAML, croaks if it contains more than one section, and otherwise returns the contained data.

$tree->as_yaml()

This method returns the entire tree of data (returned by the data method), serialized into YAML.

$tree->write_file($filename, $data)

This method writes the given data, as YAML, to the given filename.

TODO

symlinks and references

AUTHOR

Ricardo SIGNES, <rjbs@cpan.org>

BUGS

Please report any bugs or feature requests to bug-tree-file@rt.cpan.org, or through the web interface at http://rt.cpan.org. I will be notified, and then you'll automatically be notified of progress on your bug as I make changes.

COPYRIGHT

Copyright 2005 Ricardo Signes, All Rights Reserved.

This program is free software; you can redistribute it and/or modify it under the same terms as Perl itself.

Module Install Instructions

To install Tree::File::YAML, simply copy and paste either of the commands in to your terminal