[Tagging] tagging sport=shotput or sport=shot_put?

Mikael Nordfeldth mmn at hethane.se
Mon Apr 18 11:33:15 UTC 2016


Warin 61sundowner at gmail.com wrote:
> That has "Shot-put" ... note the dash, not an uderscore. So I am back
> to thinking about it.

Hi again! As I commented on the wiki talk page for "sport=shot-put"[1] I
believe the value should be normalised to "shot_put" regardless if it's
the English "shot-put" or American "shot put".

This replacement, "-" to "_", is a typical behaviour in programming (and
as the key=value setup isn't for humans anyway, I think it's logical and
appropriate to use programming practices).
In general it is good to avoid the "-" character in single words/phrases
to avoid cumbersome regular expressions (where - has to be escaped) etc.
as well as special meanings ("start-finish" enumerations for example).


Also all the tags out there, except recently changed by you, are labeled
"shot_put". I guess "shotput" could probably also work, but given the
prevalence of "shot_put" I think that choice is the path of least mistyping.


[1] https://wiki.openstreetmap.org/wiki/Talk:Tag:sport%3Dshot-put

-- 
Mikael Nordfeldth
https://blog.mmn-o.se/
XMPP/mail: mmn at hethane.se
OpenPGP Fingerprint: AE68 9813 0B7C FCE3 B2FA 727B C7CE 635B B52E

-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 819 bytes
Desc: OpenPGP digital signature
URL: <http://lists.openstreetmap.org/pipermail/tagging/attachments/20160418/5643f2f4/attachment-0001.sig>


More information about the Tagging mailing list