-
Notifications
You must be signed in to change notification settings - Fork 5
Expand file tree
/
Copy pathEDetect.pm
More file actions
executable file
·225 lines (217 loc) · 9.68 KB
/
EDetect.pm
File metadata and controls
executable file
·225 lines (217 loc) · 9.68 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
package EDetect;
use strict;
use warnings;
use Exporter qw(import);
our @EXPORT_OK = qw(editor editor_wikilink);
sub editor {
my $cr = shift;
return 'Not Specified' if $cr eq '';
return 'JOSM Reverter' if $cr =~ /reverter_plugin\/\d{5}/;
return 'JOSM' if $cr =~ /^(?:.+;)?JOSM/;
return 'iD' if $cr =~ /^iD/;
return 'Potlatch 0.x/1.x' if $cr =~ /^Potlatch [01]/;
return 'Potlatch 2' if $cr =~ /^Potlatch 2/;
return 'Potlatch 3' if $cr =~ /^Potlatch$/;
return 'Merkaartor' if $cr =~ /^Merkaartor/;
return 'Vespucci' if $cr =~ /^Vespucci/;
return 'Go Map!!' if $cr =~ /^Go (?:Map|Kaart)/;
return 'Pushpin' if $cr =~ /^Pushpin/;
return 'OsmAnd' if $cr =~ /^Osm[Aa]nd/;
return 'MAPS.ME' if $cr =~ /^MAPS\.ME/;
return 'rosemary' if $cr =~ /^rosemary/;
return 'rosemary' if $cr =~ /^wheelmap\.org/;
return 'bulk_upload.py' if $cr =~ /^bulk_upload\.py/;
return 'PythonOsmApi' if $cr =~ /PythonOsmApi/;
return 'OSMPOIEditor' if $cr =~ /^POI\+/;
return 'OSMPOIEditor' if $cr =~ /^OSMPOIEditor/;
return 'Level0' if $cr =~ /^Level0/;
return 'Osmose Editor' if $cr =~ /^Osmose Editor/;
return 'RawEdit' if $cr =~ /^RawEdit/;
return 'RawEdit' if $cr =~ /^Osmose Raw Editor/;
return 'OsmHydrant' if $cr =~ /^OsmHydrant/;
return 'iLOE' if $cr =~ /^iLOE/;
return 'YAPIS' if $cr =~ /^YAPIS/;
return 'Services_OSM' if $cr =~ /^Services_OpenStreetMap/;
return 'ArcGIS' if $cr =~ /^ArcGIS Editor/;
return 'osmapis' if $cr =~ /^osmapis/;
return 'osmapi' if $cr =~ /^osmapi(?:\/.+)?$/;
return 'FreieTonne' if $cr =~ /^FreieTonne/;
return 'osmtools' if $cr =~ /^osmtools\//;
return 'Redaction bot' if $cr =~ /^Redaction bot/;
return 'upload.py' if $cr =~ /^(?:.*\/)?upload\.py/;
return 'bulk_upload.py' if $cr =~ /^bulk_upload\.py/;
return 'bulk_upload_sax.py' if $cr =~ /^bulk_upload_sax\.py/;
return 'OpenMaps' if $cr =~ /^OpenMaps /;
return 'Mapzen' if $cr =~ /^Mapzen /;
return 'WebDRI' if $cr =~ /^WebDRI/;
return 'KMLManager' if $cr =~ /^KMLManager/;
return 'osmitter' if $cr =~ /^osmitter/;
return 'COFFEEDEX 2002' if $cr =~ /^COFFEEDEX 2002/;
return 'FindvejBot' if $cr =~ /^FindvejBot/;
return 'Roy' if $cr =~ /^Roy /;
return 'OSMPhpLib'if $cr =~ /^OSMPhpLib/;
return 'Fulcrum' if $cr =~ /^Fulcrum /;
return 'OSMapTuner' if $cr =~ /^OSMapTuner/;
return 'QGIS' if $cr =~ /^QGIS /;
return 'OpenSeaMap-Editor' if $cr =~ /^OpenSeaMap-Editor/;
return 'BigTinCan' if $cr =~ /^BigTinCan /;
return 'meta' if $cr =~ /^meta$/;
return 'SviMik' if $cr =~ /^SviMik/;
return 'My Opening Hours' if $cr =~ /^My Opening Hours/;
return 'Sputnik.Ru.Adminka' if $cr =~ /^Sputnik\.Ru\.Adminka/;
return 'OpenBeerMap' if $cr =~ /^OpenBeerMap/;
return 'Kort' if $cr =~ /^Kort /;
return 'Nomino' if $cr =~ /Nomino /;
return 'Route4U' if $cr =~ /^Route4U/;
return 'Ubiflow' if $cr =~ /^Ubiflow/;
return 'streetkeysmv' if $cr =~ /^streetkeysmv/;
return 'Grass and Green' if $cr =~ /^Grass_and_Green/;
return 'fix.loggingroads.org' if $cr =~ /^fix\.loggingroads\.org/;
return 'MapStalt Mini' if $cr =~ /^MapStalt Mini/;
return 'osmupload.py' if $cr =~ /^osmupload\.py/;
return "Jeff's Uploader" if $cr =~ /^Jeff's Uploader/;
return 'AND node cleaner/retagger' if $cr =~ /^AND /;
return 'MyUploader' if $cr =~ /^MyUploader/;
return 'Tayberry' if $cr =~ /^Tayberry/;
return 'GNOME Maps' if $cr =~ /^gnome-maps/;
return 'StreetComplete' if $cr =~ /^StreetComplete /;
return 'StreetComplete EE' if $cr =~ /^StreetComplete_ee /;
return 'FireYak' if $cr =~ /^FireYak/;
return 'MapContrib' if $cr =~ /^MapContrib/;
return 'Geocropping' if $cr =~ /^Geocropping/;
return 'RevertUI' if $cr =~ /^RevertUI/;
return 'OSM ↔ Wikidata' if $cr =~ /osm\.wikidata\.link/;
return 'OSM Contributor' if $cr =~ /^OSM Contributor/;
return 'Jungle Bus' if $cr =~ /^Jungle Bus/;
return 'IsraelHiking' if $cr =~ /^IsraelHiking\.osm/;
return 'RocketData' if $cr =~ /^rocketdata\.io/;
return 'Pic4Review' if $cr =~ /^Pic4Review/;
return 'Tracks Editor' if $cr =~ /^Tracks Editor/;
return 'Data4All' if $cr =~ /^Data4All/;
return 'CityZen' if $cr =~ /^CityZen/;
return 'Osm2go' if $cr =~ /^osm2go /;
return 'AutoAWS' if $cr =~ /^autoAWS/;
return 'DEVK Versicherung' if $cr =~ /^DEVK Versicherung/;
return 'osm for ruby' if $cr =~ /^osm for ruby/;
return 'osmlinzaddr.py' if $cr =~ /osmlinzaddr\.py/;
return 'FixKarlsruheSchema' if $cr =~ /^FixKarlsruheSchema/;
return 'GpsMid' if $cr =~ /^GpsMid_/;
return 'AndNav2' if $cr =~ /^andnav\.org/;
return 'Deriviste' if $cr =~ /^Deriviste/;
return 'Brick' if $cr =~ /^Brick/;
return 'SketchOSM' if $cr =~ /^SketchOSM/;
return 'OSMyBiz' if $cr =~ /^OSMyBiz/;
return 'Osm Go!' if $cr =~ /^Osm Go!/;
return 'Parking Lanes' if $cr =~ /^PLanes/;
return 'Rapid' if $cr =~ /^Rapi[dD] /;
return 'TrashApp' if $cr =~ /^TrashApp/;
return 'OsmInEdit' if $cr =~ /^OsmInEdit/;
return 'MapComplete' if $cr =~ /^MapComplete/;
return 'MapRoulette' if $cr =~ /^MapRoulette/;
return 'Healthsites.io' if $cr =~ /^Healthsites\.io/;
return 'OsmPipeline' if $cr =~ /^OsmPipeline/;
return 'HTTPS All The Things' if $cr =~ /^https_all_the_things/;
return 'addr2osm' if $cr =~ /^addr2osm/;
return 'peundemerg.ro' if $cr =~ /^peundemerg.ro/;
return 'Organic Maps' if $cr =~ /^O(rganic )?Maps /;
return 'ProjetDuMois.fr' if $cr =~ /^ProjetDuMois/;
return 'posiki_python_script' if $cr =~ /^posiki_python_script/;
return 'Centaur Mapper' if $cr =~ /^Centaur Mapper/;
return 'simple_revert' if $cr =~ /^(?:simple_revert|restore-version)\.py/;
return 'POI Collector' if $cr =~ /^POI Collector v/;
return 'Locus Map POI' if $cr =~ /^LoPoi /;
return 'Mundi App' if $cr =~ /^Mundi App/;
return 'OpenRecycleMap' if $cr =~ /^OpenRecycleMap/;
return 'LINZ Import' if $cr =~ /^LINZ \w+ Import/;
return 'Every Door' if $cr =~ /^Every Door /;
return 'Mapa AED' if $cr =~ /aed\.openstreetmap\.org\.pl/;
return 'Map builder' if $cr =~ /^Map builder /;
return 'refill.bz.it' if $cr =~ /^Refill Südtirol \/ Alto Adige$/;
return 'OpenAEDMap' if $cr =~ /openaedmap\.org/;
return 'OpenAEDMap' if $cr =~ /^AED Map for/;
return 'OpenAEDMap' if $cr =~ /openaedmap-backend /;
return 'osm-revert' if $cr =~ /^osm-revert /;
return 'OpenStop' if $cr =~ /^OpenStop/;
return 'OSM Tags Editor' if $cr =~ /^Osm\.Org Tags Editor/;
return 'Relatify' if $cr =~ /^osm-relatify /;
return 'CoMaps' if $cr =~ /^CoMaps /;
return 'DeFlock' if $cr =~ /^DeFlock /;
return 'OsmAPP' if $cr =~ /^OsmAPP /;
return 'Other';
}
my %wikinames = (
'Potlatch 0.x/1.x' => 'Potlatch 1',
'Pushpin' => 'Pushpin OSM',
'PythonOsmApi' => 'Osmapi',
'OSMPOIEditor' => 'POI+',
'rosemary' => 'Rosemary',
'ArcGIS' => 'ArcGIS Editor for OSM',
'upload.py' => 'Upload.py',
'bulk_upload.py' => 'Bulk_upload.py',
'bulk_upload_sax.py' => 'Bulk_upload_sax.py',
'OpenMaps' => 'OpenMaps (IZE)',
'Kort' => 'Kort Game',
'Mapzen' => 'Mapzen POI Collector',
'iLOE' => 'ILOE',
'osmitter' => 'Osmitter',
'QGIS' => 'QGIS OSM Plugin',
'Services_OSM' => 'PHP',
'Osmose Editor' => 'Osmose#Osmose_integrated_tags_editor',
'Redaction bot' => 'OSMF Redaction Bot',
'OpenSeaMap-Editor' => 'OpenSeaMap#Editor',
'AND node cleaner/retagger' => 'AND Data',
'FixKarlsruheSchema' => 'Xybot#So_what_does_the_FixKarlsruheSchema_ruleset_do_exactly',
'Jungle Bus' => 'Jungle Bus mobile app',
'HTTPS All The Things' => 'Automated Edits/b-jazz-bot',
'OsmPipeline' => 'Import/Maine E911 Addresses',
'LINZ Import' => 'Import/New Zealand Street Addresses (2021)',
'OSM ↔ Wikidata' => 'OSM ↔ Wikidata matcher',
'JOSM Reverter' => 'JOSM/Plugins/Reverter',
'OpenStop' => 'DE:OpenStop',
'StreetComplete EE' => 'SCEE',
'OSM Tags Editor' => 'OpenStreetMap Tags Editor'
);
my @wiki_self = (
'JOSM', 'iD', 'Potlatch 2', 'Merkaartor', 'Vespucci', 'Go Map!!', 'MAPS.ME',
'OsmAnd', 'Level0', 'OsmHydrant', 'RawEdit', 'Nomino', 'My Opening Hours',
'FreieTonne', 'MapStalt Mini', 'OSMapTuner', 'MapContrib', 'StreetComplete',
'OSM Contributor', 'Tracks Editor', 'Data4All', 'CityZen', 'Potlatch 3',
'Osm2go', 'AutoAWS', 'GpsMid', 'Deriviste', 'AndNav2', 'OSMyBiz', 'Osm Go!',
'Rapid', 'OsmInEdit', 'GNOME Maps', 'MapRoulette', 'MapComplete', 'Organic Maps',
'Every Door', 'Pic4Review', 'posiki_python_script', 'RevertUI', 'osm-revert',
'Relatify', 'CoMaps', 'OsmAPP'
);
$wikinames{$_} = '' for @wiki_self;
my %websites = (
'Geocropping' => 'https://geocropping.xsalto.com/guide.html',
'IsraelHiking' => 'https://israelhiking.osm.org.il/',
'RocketData' => 'https://rocketdata.io/',
'DEVK Versicherung' => 'https://www.devk.de/',
'osmlinzaddr.py' => 'https://git.nzoss.org.nz/ewblen/osmlinzaddr',
'Brick' => 'https://edit.osmbuildings.org/',
'SketchOSM' => 'https://mindsightstudios.com/sketchosm/',
'Parking Lanes' => 'https://zlant.github.io/parking-lanes/',
'TrashApp' => 'https://trashapp.cc/',
'Healthsites.io' => 'https://healthsites.io/',
'addr2osm' => 'https://github.com/NKAmapper/addr2osm',
'peundemerg.ro' => 'https://forum.peundemerg.ro/index.php?topic=836.0',
'ProjetDuMois.fr' => 'https://projetdumois.fr/projects/2021-05_laboratory',
'OpenRecycleMap' => 'https://openrecyclemap.org/',
'Locus Map POI' => 'https://www.vastuf.com/projects/lopoi/',
'Mapa AED' => 'https://aed.openstreetmap.org.pl/',
'osmtools' => 'https://github.com/woodpeck/osm-revert-scripts',
'Map builder' => 'https://www.bing.com/mapbuilder/',
'refill.bz.it' => 'https://www.refill.bz.it/',
'OpenAEDMap' => 'https://openaedmap.org/',
'DeFlock' => 'https://deflock.me/app'
);
sub editor_wikilink {
my $e = shift;
if (exists $wikinames{$e}) {
return "[[".($wikinames{$e} ? $wikinames{$e}.'|' : '')."$e]]";
} elsif (exists $websites{$e}) {
return "[$websites{$e} $e]";
}
return $e;
}
1;