Browse files

Reverted back to Config::General.

  • Loading branch information...
1 parent b75ef36 commit 9279bb87e1c7f49fc71987b8a5ea58000b6616e8 @shlomif shlomif committed Jul 21, 2009
Showing with 35 additions and 0 deletions.
  1. +8 −0 cpanhq.conf
  2. 0 cpanhq.yml → cpanhq.yml.old
  3. +13 −0 tmp/config-general-to-yaml.pl
  4. +14 −0 tmp/yaml-to-config-general.pl
View
8 cpanhq.conf
@@ -0,0 +1,8 @@
+<Controller::Distribution>
+ graph_path __HOME__/root/dist/graph/
+</Controller::Distribution>
+name CPANHQ
+<Model::DB>
+ connect_info dbi:SQLite:dbname=__HOME__/cpanhq.db
+ connect_info undef
+</Model::DB>
View
0 cpanhq.yml → cpanhq.yml.old
File renamed without changes.
View
13 tmp/config-general-to-yaml.pl
@@ -0,0 +1,13 @@
+#!/usr/bin/perl
+
+use strict;
+use warnings;
+
+use Config::General;
+use YAML::XS qw(DumpFile);
+
+my $conf = Config::General->new("cpanhq.conf");
+
+my %config = $conf->getall();
+
+DumpFile("cpanhq.yml", \%config);
View
14 tmp/yaml-to-config-general.pl
@@ -0,0 +1,14 @@
+#!/usr/bin/perl
+
+use strict;
+use warnings;
+
+use Config::General;
+use YAML::XS qw(LoadFile);
+
+my $config = LoadFile("cpanhq.yml");
+
+my $conf_g = Config::General->new("cpanhq.conf");
+
+$conf_g->save_file("cpanhq.conf", $config);
+

0 comments on commit 9279bb8

Please sign in to comment.