Anego
view release on metacpan or search on metacpan
lib/Anego.pm view on Meta::CPAN
package Anego;
use 5.008001;
use strict;
use warnings;
use utf8;
our $VERSION = "0.02";
1;
__END__
=encoding utf-8
=head1 NAME
Anego - The database migration utility as our elder sister.
=head1 SYNOPSIS
# show status
$ anego status
RDBMS: MySQL
Database: myapp
Schema class: MyApp::DB::Schema (lib/MyApp/DB/Schema.pm)
Hash Commit message
--------------------------------------------------
e299e9f commit
1fdc91a initial commit
# migrate to latest schema
$ anego migrate
# migrate to schema of specified revision
$ anego migrate revision 1fdc91a
# show difference between current database schema and latest schema
$ anego diff
# show difference between current database schema and schema of specified revision
$ anego diff revision 1fdc91a
=head1 DESCRIPTION
Anego is database migration utility.
=head1 CONFIGURATION
Anego requires configuration file.
In default, Anego uses C<.anego.pl> as configuration file.
# .anego.pl
+{
connect_info => ['dbi:mysql:database=myapp;host=localhost', 'root'],
schema_class => 'MyApp::DB::Schema',
}
If you want to use other files for configuration, you can use C<-c> option: C<anego status -c ./config.pl>
=head1 SCHEMA CLASS
To define database schema, Anego uses L<DBIx::Schema::DSL>:
( run in 2.326 seconds using v1.01-cache-2.11-cpan-600a1bdf6e4 )