package au.gov.amsa.geo.adhoc;

import java.io.File;
import java.io.FileNotFoundException;
import java.util.List;
import java.util.regex.Pattern;

import au.gov.amsa.navigation.ShipStaticDataCreator;
import au.gov.amsa.util.Files;

public class ShipStaticDataMain {

    public static void main(String[] args) throws FileNotFoundException {
        File outputFile = new File("target/out.txt");
        // String filename = "/media/an/nmea/2014/NMEA_ITU_20140815.gz";
        List<File> files = Files.find(new File("/media/an/nmea/2014/"),
                Pattern.compile("NMEA_ITU.*.gz"));

        ShipStaticDataCreator.writeStaticDataToFile(files, outputFile).count().toBlocking()
                .single();

    }

}

@@ -334,16 +334,100 @@
 ption %7B%0A
+        System.out.println(%22started%22);%0A        long t = System.currentTimeMillis();%0A
         
@@ -468,24 +468,24 @@
 /out.txt%22);%0A
-
         // S
@@ -667,16 +667,252 @@
 *.gz%22));
+%0A        files.addAll(Files.find(new File(%22/media/an/nmea/2015/%22),%0A                Pattern.compile(%22NMEA_ITU.*.gz%22)));%0A        files.addAll(Files.find(new File(%22/media/an/nmea/2016/%22),%0A                Pattern.compile(%22NMEA_ITU.*.gz%22)));
 %0A%0A      
@@ -1024,16 +1024,117 @@
 ngle();%0A
+        t = System.currentTimeMillis() - t;%0A        System.out.println(%22finished in %22+ t/1000 + %22s%22);
 %0A    %7D%0A%0A

update for extract