yu.dong | c33b307 | 2024-08-21 23:14:49 -0700 | [diff] [blame] | 1 | #!/usr/local/bin/perl
|
| 2 | #$file = $ARGV[0];
|
| 3 | #$FIXPATH = $ARGV[1];
|
| 4 | #$RELEASE_DIR = $ARGV[2];
|
| 5 | $FIXPATH = $ARGV[0];
|
| 6 | print "$FIXPATH\n";
|
| 7 |
|
| 8 | $RELEASE_DIR = $ARGV[1];
|
| 9 | print "$RELEASE_DIR\n";
|
| 10 | shift(@ARGV);
|
| 11 | shift(@ARGV);
|
| 12 | @Files="@ARGV";
|
| 13 |
|
| 14 | open(F,">$FIXPATH\\make\\~copy.tmp") or die "Cannot open $FIXPATH\\make\\~copy.tmp";
|
| 15 | print F @Files;
|
| 16 | close(F);
|
| 17 |
|
| 18 | print "perl pcore\\tools\\lnitem.pl $FIXPATH\\make\\~copy.tmp";
|
| 19 | system("perl pcore\\tools\\lnitem.pl $FIXPATH\\make\\~copy.tmp");
|
| 20 |
|
| 21 | open(F,"<$FIXPATH\\make\\~copy.tmp") or die "Cannot open $file: $!";
|
| 22 | while(<F>) {
|
| 23 | chomp($_);
|
| 24 | if (-e $_) {
|
| 25 | if(!-e "$RELEASE_DIR\\$_") {
|
| 26 | system("md $RELEASE_DIR\\$_");
|
| 27 | system("rd $RELEASE_DIR\\$_");
|
| 28 | }
|
| 29 | print "copy /y $FIXPATH\\$_ $RELEASE_DIR\\$_\n";
|
| 30 | system("copy /y $FIXPATH\\$_ $RELEASE_DIR\\$_");
|
| 31 | } else {
|
| 32 | chop($_);
|
| 33 | if(!-e "$RELEASE_DIR\\$_") {
|
| 34 | system("md $RELEASE_DIR\\$_");
|
| 35 | system("rd $RELEASE_DIR\\$_");
|
| 36 | }
|
| 37 | print "copy /y $FIXPATH\\$_ $RELEASE_DIR\\$_\n";
|
| 38 | system("copy /y $FIXPATH\\$_ $RELEASE_DIR\\$_");
|
| 39 | }
|
| 40 | }
|
| 41 | close(F);
|