use MooseX::Types::JSON qw(JSON);
use MooseX::Types::Path::Class qw(Dir File);
use Try::Tiny;
-use JSON::Any;
+use JSON::Any qw(DWIW XS JSON);
use namespace::autoclean;
-
=head1 NAME
DBIx::Class::Admin - Administration object for schemas
$ dbicadmin --schema=MyApp::Schema --class=Employee \
--connect='["dbi:SQLite:my.db", "", ""]' \
- --op=update --set='{"name":"New_Employee"}'
+ --op=update --set='{ "name": "New_Employee" }'
use DBIx::Class::Admin;
L<JSON::Any>
+(L<JSON::DWIW> preferred for barekey support)
+
L<namespace::autoclean>
L<Getopt::Long::Descriptive>
sub _build_config {
my ($self) = @_;
- try { require Config::Any } catch { $self->throw_exception( "Config::Any is required to parse the config file"); };
+
+ eval { require Config::Any }
+ or $self->throw_exception( "Config::Any is required to parse the config file");
my $cfg = Config::Any->load_files ( {files => [$self->config_file], use_ext =>1, flatten_to_hash=>1});