From: Chris W. <la...@us...> - 2005-03-16 03:56:13
|
Update of /cvsroot/openinteract/OpenInteract2/script In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv22044 Modified Files: oi2_manage Log Message: OIN-125: screen ugly package filenames Index: oi2_manage =================================================================== RCS file: /cvsroot/openinteract/OpenInteract2/script/oi2_manage,v retrieving revision 1.32 retrieving revision 1.33 diff -C2 -d -r1.32 -r1.33 *** oi2_manage 17 Feb 2005 05:05:52 -0000 1.32 --- oi2_manage 16 Mar 2005 03:55:55 -0000 1.33 *************** *** 48,58 **** my $HELP_LIST = 'ope...@li...'; ! my ( $OPT_help, $OPT_debug, $OPT_man, $OPT_use_status, $OPT_task ); { my @opt_defs = OpenInteract2::Manage->all_parameters_long_options; ! push @opt_defs, 'help|?', 'debug+', 'man', 'status', 'task=s'; my %OPT = ( help => \$OPT_help, debug => \$OPT_debug, ! man => \$OPT_man, status => \$OPT_use_status, task => \$OPT_task ); GetOptions( \%OPT, @opt_defs ); --- 48,58 ---- my $HELP_LIST = 'ope...@li...'; ! my ( $OPT_help, $OPT_debug, $OPT_man, $OPT_verbose, $OPT_task ); { my @opt_defs = OpenInteract2::Manage->all_parameters_long_options; ! push @opt_defs, 'help|?', 'debug+', 'man', 'verbose', 'task=s'; my %OPT = ( help => \$OPT_help, debug => \$OPT_debug, ! man => \$OPT_man, status => \$OPT_verbose, task => \$OPT_task ); GetOptions( \%OPT, @opt_defs ); *************** *** 141,145 **** # delete our own entries... ! delete @OPT{ qw( help man status task ) }; # derefrence the debug entry --- 141,145 ---- # delete our own entries... ! delete @OPT{ qw( help man verbose task ) }; # derefrence the debug entry *************** *** 148,152 **** my $task = eval { OpenInteract2::Manage->new( $task_name, \%OPT ) }; if ( $@ ) { ! outl( "Task '$task_name' has not been recognized" ); out( "Error returned: $@" ); exit(1); --- 148,152 ---- my $task = eval { OpenInteract2::Manage->new( $task_name, \%OPT ) }; if ( $@ ) { ! outl( "Task '$task_name' not recognized" ); out( "Error returned: $@" ); exit(1); *************** *** 155,166 **** $log->debug( show_parameter_contents( $task ) ); ! if ( $OPT_use_status ) { $task->add_observer( \&status_observer ); $log->debug( "Added status observer" ); } ! else { ! $task->add_observer( \&progress_observer ); ! $log->debug( "Added normal progress observer" ); ! } eval { $task->execute }; if ( $@ ) { --- 155,164 ---- $log->debug( show_parameter_contents( $task ) ); ! if ( $OPT_verbose ) { $task->add_observer( \&status_observer ); $log->debug( "Added status observer" ); } ! $task->add_observer( \&progress_observer ); ! $log->debug( "Added normal progress observer" ); eval { $task->execute }; if ( $@ ) { *************** *** 189,193 **** foreach my $item_status ( @{ $action_status->{status} } ) { if ( $item_status->{is_ok} eq 'yes' ) { ! if ( $item_status->{filename} ) { warn " OK: $item_status->{filename}\n"; if ( $item_status->{message} ) { --- 187,192 ---- foreach my $item_status ( @{ $action_status->{status} } ) { if ( $item_status->{is_ok} eq 'yes' ) { ! # TODO: replace hack when we fix progress/summarization features ! if ( $item_status->{filename} and $item_status->{filename} !~ /^OIPKG/ ) { warn " OK: $item_status->{filename}\n"; if ( $item_status->{message} ) { *************** *** 203,207 **** if ( $item_status->{filename} ) { warn " FAILED: $item_status->{filename}\n", ! " $item_status->{message}\n"; } else { --- 202,206 ---- if ( $item_status->{filename} ) { warn " FAILED: $item_status->{filename}\n", ! " $item_status->{message}\n"; } else { *************** *** 235,242 **** \$ oi2_manage task_info --task=taskname -- information about a particular task, including parameters ! \$ oi2_manage create_website --website_dir=/path --source_dir=/path -- create a new website \$ oi2_manage list_actions --website_dir=/path -- list the actions in an existing website Learn more: --- 234,243 ---- \$ oi2_manage task_info --task=taskname -- information about a particular task, including parameters ! \$ oi2_manage create_website --website_dir=/path -- create a new website \$ oi2_manage list_actions --website_dir=/path -- list the actions in an existing website + \$ oi2_manage create_package --package=myapp + --create a new package Learn more: *************** *** 307,311 **** my ( $err ) = @_; my $out = "One or more parameters failed task checks. Task not executed.\n". ! "Here are the parameters that failed and the reason for each.\n\n"; my $failed = $err->parameter_fail || {}; while ( my ( $field, $fail ) = each %{ $failed } ) { --- 308,312 ---- my ( $err ) = @_; my $out = "One or more parameters failed task checks. Task not executed.\n". ! "Parameter failures:\n\n"; my $failed = $err->parameter_fail || {}; while ( my ( $field, $fail ) = each %{ $failed } ) { |