# `mix tz_world.update`
[🔗](https://github.com/kipcole9/tz_world/blob/v2.5.0/lib/mix/tasks/update_timezones_geojson.ex#L1)

Downloads and installs the latest Timezone GeoJSON data.

## Arguments

* `--include-oceans` (`-o`) will include the geojson for the oceans
  in the downloaded data. The default is to download data without
  ocean coverage.

* `--force` (`-f`) does two things:
    * Forces an update even if the currently installed data is
      already at the latest release. Useful when switching
      between including and excluding ocean coverage.
    * Creates the directory configured under `:data_dir` if it
      does not yet exist. Without `--force` a missing `:data_dir`
      is reported as an error so a misconfigured `:data_dir` is
      loud rather than silently materialised. Pass `--force` on
      the first install when you have set a custom `:data_dir`
      that is not part of the build artifacts.

* `--backends` (`-b`) is a comma separated list of the backends the
  installed data must serve. The default is `spatial_index`.

  The `.tzw1` data file is the source of truth and is always written.
  Naming `dets` additionally builds `timezones-geodata.dets`, the
  on-disk cache `TzWorld.Backend.DetsWithIndexCache` reads and that
  `TzWorld.Backend.EtsWithIndexCache` loads into ETS at startup, so
  naming `ets` builds it too. That file is an order of magnitude
  larger than the `.tzw1`, and `TzWorld.Backend.SpatialIndex` reads
  the `.tzw1` directly and never needs it, so the default does not
  build it.

  Accepted names are `spatial_index`, `ets` and `dets`. `ets` and
  `dets` are deprecated and will be removed in the next release.

      mix tz_world.update --backends dets
      mix tz_world.update --backends spatial_index,dets

* `--trace` (`-t`) emits debug-level progress logs (current memory
  usage, download / extract / parse phases).

# `run`

---

*Consult [api-reference.md](api-reference.md) for complete listing*
