conversion: polygon layer shapefile into OSM

I hunted around quite a bit, and didn’t find anything which seemed to do what I needed to (proof of concept to cleanly and fully convert various ESRI shapefiles consisting of nothing but area polygons to OSM format) so I cobbled a solution together.

Did I miss something, and this was readily doable without much effort, or is this something I should make a bit more polished and publish someplace?

There are some shp2osm converters, i believe shp2osm handles polygons. Don’t know though if they convert multipolygons (don’t know if your program does that). But imo the more converters the better, it is always better to put them somewhere on SVN then to let them on a harddrive.