#!/usr/bin/perl -w -T
# +=========================================================================+
# || cipux_cat_web_configuration                                           ||
# ||                                                                       ||
# || Copyright (C) 2010 by Christian Kuelker                               ||
# +=========================================================================+
# ID:       $Id$
# Revision: $Revision$
# Head URL: $HeadURL$
# Date:     $Date$
# Source:   $Source$

use strict;
use warnings;
use Carp qw(confess);
use CipUX::CAT::Web;

#use Data::Dumper;
#use English qw( -no_match_vars );
use Log::Log4perl qw(get_logger :levels);
use YAML::Any;

# debug
my $debug = 0;
if ($debug) {
    Log::Log4perl::init_once('/usr/share/cipux/etc/cipux-cat-web.log4perl');
}

# extensions
my $cipux  = CipUX->new();
my @ext    = sort $cipux->cfg_ext();
my $ext_hr = {};
$ext_hr->{extension} = \@ext;
$cipux->out("# === CipUX (supported configuration extensions) ===\n");
print YAML::Any::Dump($ext_hr) or confess "Can not print to STDOUT!\n";

# cipux-cat-web
my $ccw    = CipUX::CAT::Web->new;
my $cfg_hr = $ccw->get_cat_web_cfg();
$cipux->out("# === CipUX (scope cipux-cat-web) ===\n");
print YAML::Any::Dump($cfg_hr) or confess "Can not print to STDOUT!\n";

