Changeset 21410 for trunk/pstamp/scripts/request_finish.pl
- Timestamp:
- Feb 6, 2009, 5:44:55 PM (17 years ago)
- File:
-
- 1 edited
-
trunk/pstamp/scripts/request_finish.pl (modified) (5 diffs)
Legend:
- Unmodified
- Added
- Removed
-
trunk/pstamp/scripts/request_finish.pl
r19221 r21410 13 13 use File::Temp qw( tempfile ); 14 14 use File::Copy; 15 use File::Basename qw( dirname ); 15 16 16 17 use PS::IPP::Metadata::Config; … … 20 21 use PS::IPP::Config qw( :standard ); 21 22 22 my ( $req_id, $req_name, $req_file, $req_type, $ product, $dbname, $verbose, $save_temps);23 my ( $req_id, $req_name, $req_file, $req_type, $out_dir, $product, $dbname, $verbose, $save_temps, $redirect_output ); 23 24 24 25 GetOptions( … … 27 28 'req_file=s' => \$req_file, 28 29 'req_type=s' => \$req_type, 30 'out_dir=s' => \$out_dir, 29 31 'product=s' => \$product, 30 32 'dbname=s' => \$dbname, 31 33 'verbose' => \$verbose, 32 34 'save-temps' => \$save_temps, 35 'redirect-output' => \$redirect_output, 33 36 ) or pod2usage( 2 ); 34 37 … … 42 45 $err .= "--req_name is required\n" if !$req_name; 43 46 $err .= "--product is required\n" if !$product; 47 # $err .= "--out_dir is required\n" if !$out_dir; 44 48 45 49 die "$err" if $err; 50 51 52 if (!$out_dir) { 53 $out_dir = dirname($req_file); 54 } 55 56 if ($redirect_output) { 57 my $logDest = "$out_dir/reqfinish.$req_id.log"; 58 my $ipprc = PS::IPP::Config->new(); 59 $ipprc->redirect_output($logDest); 60 } 46 61 47 62 my $missing_tools; … … 63 78 } 64 79 if ($finish_cmd) { 65 my $command = $finish_cmd . " --req_id $req_id --req_name $req_name --req_file $req_file --product $product ";80 my $command = $finish_cmd . " --req_id $req_id --req_name $req_name --req_file $req_file --product $product --out_dir $out_dir"; 66 81 $command .= " --dbname $dbname" if $dbname; 67 82 $command .= " --verbose" if $verbose;
Note:
See TracChangeset
for help on using the changeset viewer.
