Here’s a script I use to test the validy of a .yml (YAML) file.
#!/usr/bin/perl use strict; use warnings; use YAML::Syck; use Data::Dump qw( dump ); use Getopt::Std; our ($opt_d); getopts(‘d’); for my $file (@ARGV) { print “checking $file …”; my $buf = LoadFile($file); print “ok\n”; print( dump($buf), “\n” ) if $opt_d; }