aboutsummaryrefslogtreecommitdiff
path: root/src/test/recovery/t/cp_history_files
blob: 66f1b598fea81e70549a1a2727a822a663c10288 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
#!/usr/bin/perl

use File::Copy;
use strict;
use warnings;

die "wrong number of arguments" if @ARGV != 2;
my ($source, $target) = @ARGV;
exit if $source !~ /history/;
if ($^O eq 'msys')
{
    # make a windows path look like an msys path if necessary
    $source =~ s!^([A-Za-z]):!'/' . lc($1)!e;
    $source =~ s!\\!/!g;
}

copy($source, $target) or die "couldn't copy $source to $target: $!";