Index: trunk/scripts/SyncEditorImageryIndex.groovy
===================================================================
--- trunk/scripts/SyncEditorImageryIndex.groovy	(revision 11415)
+++ trunk/scripts/SyncEditorImageryIndex.groovy	(revision 11420)
@@ -34,4 +34,5 @@
     def eiiUrls = new HashMap<String, JsonObject>()
     def josmUrls = new HashMap<String, ImageryInfo>()
+    def josmMirrors = new HashMap<String, ImageryInfo>()
 
     static String eiiInputFile = 'imagery.geojson'
@@ -206,5 +207,5 @@
                 myprintln "+++ JOSM-URL is not unique: "+url
             } else {
-              josmUrls.put(url, e)
+                josmUrls.put(url, e)
             }
             for (def m : e.getMirrors()) {
@@ -213,5 +214,6 @@
                     myprintln "+++ JOSM-Mirror-URL is not unique: "+url
                 } else {
-                  josmUrls.put(url, m)
+                    josmUrls.put(url, m)
+                    josmMirrors.put(url, m)
                 }
             }
@@ -385,4 +387,39 @@
             }
         }
+        myprintln "*** Mismatching icons: ***"
+        for (def url : eiiUrls.keySet()) {
+            def e = eiiUrls.get(url)
+            if (!josmUrls.containsKey(url)) {
+                continue
+            }
+            def j = josmUrls.get(url)
+            def ij = getIcon(j)
+            def ie = getIcon(e)
+            if(ij != null && ie == null) {
+                if(!options.nomissingeii) {
+                    myprintln "+ No EII icon: ${getDescription(j)}"
+                }
+            } else if(ij == null && ie != null) {
+                myprintln "- No JOSM icon: ${getDescription(j)}"
+            } else if(!ij.equals(ie)) {
+                myprintln "* Different icons: ${getDescription(j)}"
+            }
+        }
+        myprintln "*** Miscellaneous checks: ***"
+        def josmIds = new HashMap<String, ImageryInfo>()
+        for (def url : josmUrls.keySet()) {
+            def j = josmUrls.get(url)
+            def id = getId(j)
+            if(josmMirrors.containsKey(url)) {
+                continue;
+            }
+            if(id == null) {
+                myprintln "* No JOSM-ID: ${getDescription(j)}"
+            } else if(josmIds.containsKey(id)) {
+                myprintln "* JOSM-ID ${id} not unique: ${getDescription(j)}"
+            } else {
+                josmIds.put(id, j);
+            }
+        }
     }
 
@@ -393,4 +430,8 @@
         if (e instanceof ImageryInfo) return e.url
         return e.get("properties").getString("url")
+    }
+    static String getId(Object e) {
+        if (e instanceof ImageryInfo) return e.getId()
+        return e.get("properties").getString("id")
     }
     static String getName(Object e) {
@@ -458,4 +499,8 @@
         return e.get("properties").get("best") ? "best" : null
     }
+    static String getIcon(Object e) {
+        if (e instanceof ImageryInfo) return e.getIcon()
+        return e.get("properties").getString("icon", null)
+    }
     String getDescription(Object o) {
         def url = getUrl(o)
