Skip to content

v2.0.0

Latest

Choose a tag to compare

@trasch trasch released this 06 Jul 13:04

Breaking changes

  • Minimum Swift version raised to 6.3 — older toolchains no longer supported
  • layerWhitelist renamed to layerAllowlist across the entire API
  • QueryParser extracted to gis-tools — no longer part of the mvt-tools library; available via import GISTools
  • gis-tools dependency updated to 2.0.5 — see gis-tools release notes for improvements

New format support

  • MapLibre Tiles (MLT) — full read/write support via C++ bridge, including clipping, simplification, and all projection/geometry types
  • GPX import/export — read and write GPX 1.1 files; waypoints, routes, and tracks are automatically split into separate layers
  • Shapefile import/export — read ESRI Shapefiles; write single-file or per-layer directory export with mixed-geometry detection
  • GeoPackage import/export — read and write OGC GeoPackage files; supports single-table and per-layer export with "gpkg_layer" metadata for full roundtrip fidelity

CLI overhaul

  • All subcommands (dump, info, query, merge, import, export) accept all input formats — MVT, MLT, GeoJSON, GPX, Shapefile, GeoPackage
  • merge outputs to any format — not just MVT and GeoJSON
  • import and export are aliases for merge — identical behavior, same options
  • Unified TileFormat dispatch — format auto-detection from file extension; tile coordinates only required for MVT/MLT
  • --layer-name option added to merge and import commands
  • Layer filtering (--layer/--drop-layer) works consistently across all formats
  • Simplification options (--simplify-meters/--simplify-extents) now apply to GPX, Shapefile, and GeoPackage output (not just MVT/MLT/GeoJSON)

Query language improvements

  • Parenthesized grouping — (A AND B) OR C syntax now supported
  • Spatial predicates — near(lat, lon, tolerance), within(minLon, minLat, maxLon, maxLat), intersects(minLon, minLat, maxLon, maxLat)
  • String operators — =* (contains), =^ (starts with), =$ (ends with), =~ (regex with /i flag)
  • Set membership — .class in ["primary", "secondary"]
  • not and exists operators — truthy check and negation
  • Cross-type numeric comparisons — Int vs Double vs UInt8 etc. work automatically
  • Robust whitespace handling — tabs, newlines, and carriage returns accepted
  • Missing property comparisons return false (no crash) instead of aborting evaluation

Library improvements

  • MVT encoder crash fixed — NSNumber/NSDecimalNumber property values (from JSON deserialization on Linux) now bridge to native Swift types before use as dictionary keys, eliminating a signal 11 crash
  • Export options for all formats — ExportOptions with buffering/clipping and simplification now accepted by GPX, Shapefile, and GeoPackage write methods
  • FeatureCollection.query(term:) and [Feature].query(term:) convenience methods available in gis-tools