mapbox / minjur

Osmium-based converter of OSM data to GeoJSON
ISC License
59 stars 14 forks source link

Add an option to include the node IDs as an attribute of the way #29

Closed e-n-f closed 7 years ago

e-n-f commented 7 years ago

@joto Is there a better way than this to preserve the node IDs of each way into the GeoJSON?

joto commented 7 years ago

Wouldn't it make more sense to add an array with IDs and not a string?

In any case the code seems overcomplex creating a std::map<std::string, std::string> and copying it around!

e-n-f commented 7 years ago

Good point: it's only vector tiles that don't have a native way of handling array attributes; GeoJSON is fine with them.

I used the map because it seemed like it would generalize better to other potential future needs, but I'll change it to just handle this specific case instead.

joto commented 7 years ago

The upcoming osmium export command (#28) supports adding way node ids to the output by setting an option in the config file.

Please have a look whether this does all it needs to do.

Because minjur is being phased out, this will not be changed in minjur any more.

e-n-f commented 7 years ago

Thanks @joto! It looks like osmium export will take care of this.