I feel a bit stupid - but how do I upload an osm-file in JOSM? When I load it into JOSM, the upload arrow is grayed out. Unifying my file layer with a fresh download of the same POIs doesn’t change anything. The layer state in the file’s header is not set.
I had been working in the very file in a text editor and now want to upload my changes. There must be a way but maybe it is just too late in the evening for me to see …
Same thing in Level0. Nothing had been changed, so nothing to upload, Level0 tells me. Not at all, each POI I am trying to upload has been changed!
How do I get this done?
It has been a while since I manually edited a .osm file but my recollection is that each changed object needs something marking it as changed in the XML attributes. And maybe something in the header information. It has been long enough that I don’t remember the details.
The way I figured this out originally was to down load an area in JOSM, save it to a .osm file, then make a simple change and save it again to a different .osm file then compare the two files to see how the change was recorded.
I don’t use JOSM, but what you indicate about RAW editing with a code/text editor and using Level0 as an intermediary to upload to OSM I tried to do on several occasions. On a few occasions I was able to do it and I don’t remember the steps very well, there was something about copy/cut and paste the imported data in the same window of Level0 or in a different browser window.
You can also contact Ilya Zverev in the OpenStreetMap RU Telegram group and ask.
Upload only possible after you have done at least one edit in JOSM.
“Standard” XML format OSM files do not contain any information on which elements have changed / are newly created / deleted. JOSM and Vespucci (fwiw) extend the format to include such information, without that there is no way for an application to know what to upload. See JOSM file format - OpenStreetMap Wiki
I’m not sure what your motivation is to manually edit the data to start with, as this is error prone and any editor worth its salt will allow tag changes on multiple selected objects without resorting to such methods.
Thanks for your replies. Interesting, I assumed that working in a raw .osm file were quite common, like for fixing non-standard format phone numbers and the like.
In this case, the background was this mechanical edit. As a workaround, in the end I did it without raw editing but in level0, opening the result of an overpass query there and copying text from there into a text editor for editing and pasting it back.
There are numerous better ways to make bot edits (level0 for trivial search-replace, JOSM with its filtering tools, scripting, Maproulette and so on).
In line with what others have already said - there is normally no reason whatsoever to need to do this. Generally the process is “download what you want to change in JOSM” / “change what you want to change in JOSM” / “upload”. That’s less error-prone because if you have (for example) selected more data than you intended to it’ll be immediately obvious before the next step of the process.