#use FrBr::Backup::App;
require FrBr::Backup::App;
-use version; our $VERSION = qv("0.0.1");
+use version; our $VERSION = qv("0.0.2");
my $opts = {
-# 'progname' => 'backup-per-ftp',
+ 'progname' => 'backup-per-ftp',
'ftp_auto_login' => 0,
};
my $app = FrBr::Backup::App->new_with_options(%$opts);
-#exit($app->exit_code);
-exit 0;
+$app->run();
+
+exit($app->exit_code);
+#exit 0;
#--------------------------------------------------------------------------------
}
+#---------------------------------
+
+=head2 run( )
+
+Die eigentliche Startroutine der Anwendung.
+
+=cut
+
+sub run {
+
+ my $self = shift;
+
+ $self->info( "Verbinde mich FTP-Server ..." );
+
+ unless ( $self->init_ftp() ) {
+ $self->exit_code( 5 );
+ return;
+ }
+
+ unless ( $self->login_ftp() ) {
+ $self->exit_code( 6 );
+ return;
+ }
+
+ $self->info( "Beginne Backup." );
+
+}
###################################################################################