YAML provides a means of storing arbitrarily complex data structures. It also permits easy human hack^Wediting.
This code snippet passes the result of loading a YAML file through a TT template, allowing you to quickly see the results.
Uses include trying out features of Template Toolkit, template debugging, quick report generation.
#!/usr/local/bin/perl use strict; use warnings; use YAML qw/LoadFile/; use Template; my $tt = Template->new; $tt->process($ARGV[1], LoadFile($ARGV[0])) or die $tt->error;
In reply to Using YAML with Template Toolkit by rinceWind
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |