public static WriteableTileArchive newWriter(TileArchiveConfig archive, PlanetilerConfig config)
    throws IOException {
    var options = archive.applyFallbacks(config.arguments());
    var format = archive.format();
    return switch (format) {
      case MBTILES ->
        // pass-through legacy arguments for fallback
        Mbtiles.newWriteToFileDatabase(archive.getLocalPath(), options.orElse(config.arguments()
          .subset(Mbtiles.LEGACY_VACUUM_ANALYZE, Mbtiles.LEGACY_COMPACT_DB, Mbtiles.LEGACY_SKIP_INDEX_CREATION)));
      case PMTILES -> WriteablePmtiles.newWriteToFile(archive.getLocalPath());
      case CSV, TSV -> WriteableCsvArchive.newWriteToFile(format, archive.getLocalPath(),
        new StreamArchiveConfig(config, options));
      case PROTO, PBF -> WriteableProtoStreamArchive.newWriteToFile(archive.getLocalPath(),
        new StreamArchiveConfig(config, options));
      case JSON -> WriteableJsonStreamArchive.newWriteToFile(archive.getLocalPath(),
        new StreamArchiveConfig(config, options));
      case FILES -> WriteableFilesArchive.newWriter(archive.getLocalPath(), options, config.force() || config.append());
    };
  }
Returns a new {@link WriteableTileArchive} from the string definition in {@code archive}.

@throws IOException if an error occurs creating the resource.
planetiler-core/src/main/java/com/onthegomap/planetiler/archive/TileArchives.java