#!/usr/bin/perl

unless (-d "data") { system "mkdir data"; }

open(IN, "file_list.txt");
while (<IN>) {
  chomp $_; $fq = $_;
  unless (-e $fq) { print "ERROR: Did not find $fq; skipping this one.\n"; next; }
  @ar = split/\//, $fq; $fqShort = $ar[$#ar];
  next if (-e "data/$fqShort");
  print "cp $fq data/$fqShort &\n";
}
close(IN);

