Changeset 29398 for other-projects/nightly-tasks/diffcol/trunk/task.pl
- Timestamp:
- 2014-10-21T22:06:53+13:00 (10 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
other-projects/nightly-tasks/diffcol/trunk/task.pl
r28661 r29398 22 22 23 23 use Cwd; 24 use Switch; # for switch(val) { case: ; ...}24 #use Switch; # for switch(val) { case: ; ...} 25 25 use File::Path; # for rmdir and mkdir type functions 26 26 use File::Copy; # for recursive copying of folders but skipping .svn … … 140 140 141 141 if(scalar(@ARGV) > 0) { 142 switch ($ARGV[0]) { 143 case qr/^(-h|--?help|help)$/i { &printusage; exit 0; } 144 case qr/^(setup_greenstone|run_test|summarise|upload|all)$/ { $action=$ARGV[0]; } 145 else { 146 print STDERR "**** Bad subcommand.\n"; 147 &printusage; 148 exit -1; 149 } 142 #switch ($ARGV[0]) { 143 #case qr/^(-h|--?help|help)$/i { &printusage; exit 0; } 144 #case qr/^(setup_greenstone|run_test|summarise|upload|all)$/ { $action=$ARGV[0]; } 145 #else { 146 #print STDERR "**** Bad subcommand.\n"; 147 #&printusage; 148 #exit -1; 149 #} 150 #} 151 152 153 my $switch = $ARGV[0]; 154 if($switch =~ m/^(-h|--?help|help)$/i) { 155 &printusage; 156 exit 0; 157 } elsif ($switch =~ m/^(setup_greenstone|run_test|summarise|upload|all)$/) { 158 $action=$ARGV[0]; 159 } else { 160 print STDERR "**** Bad subcommand.\n"; 161 &printusage; 162 exit -1; 150 163 } 151 164
Note:
See TracChangeset
for help on using the changeset viewer.