columbus3 0.4.0 → 0.5.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/.gitignore +1 -1
- data/README.md +122 -0
- data/bin/console +0 -0
- data/bin/setup +0 -0
- data/bower.json +25 -0
- data/bower_components/jquery/.bower.json +7 -20
- data/bower_components/jquery/AUTHORS.txt +301 -0
- data/bower_components/jquery/{MIT-LICENSE.txt → LICENSE.txt} +17 -2
- data/bower_components/jquery/README.md +67 -0
- data/bower_components/jquery/bower.json +2 -16
- data/bower_components/jquery/dist/core.js +476 -0
- data/bower_components/jquery/dist/jquery.js +3861 -2818
- data/bower_components/jquery/dist/jquery.min.js +4 -5
- data/bower_components/jquery/dist/jquery.min.map +1 -1
- data/bower_components/jquery/dist/jquery.slim.js +8160 -0
- data/bower_components/jquery/dist/jquery.slim.min.js +4 -0
- data/bower_components/jquery/dist/jquery.slim.min.map +1 -0
- data/bower_components/jquery/external/sizzle/LICENSE.txt +36 -0
- data/bower_components/jquery/{src → external}/sizzle/dist/sizzle.js +445 -240
- data/bower_components/jquery/external/sizzle/dist/sizzle.min.js +3 -0
- data/bower_components/jquery/external/sizzle/dist/sizzle.min.map +1 -0
- data/bower_components/jquery/src/.eslintrc.json +5 -0
- data/bower_components/jquery/src/ajax.js +174 -105
- data/bower_components/jquery/src/ajax/jsonp.js +27 -14
- data/bower_components/jquery/src/ajax/load.js +24 -23
- data/bower_components/jquery/src/ajax/parseXML.js +8 -6
- data/bower_components/jquery/src/ajax/script.js +25 -12
- data/bower_components/jquery/src/ajax/var/location.js +5 -0
- data/bower_components/jquery/src/ajax/var/nonce.js +4 -2
- data/bower_components/jquery/src/ajax/var/rquery.js +5 -3
- data/bower_components/jquery/src/ajax/xhr.js +76 -43
- data/bower_components/jquery/src/attributes.js +4 -2
- data/bower_components/jquery/src/attributes/attr.js +60 -60
- data/bower_components/jquery/src/attributes/classes.js +87 -71
- data/bower_components/jquery/src/attributes/prop.js +81 -32
- data/bower_components/jquery/src/attributes/support.js +11 -13
- data/bower_components/jquery/src/attributes/val.js +66 -37
- data/bower_components/jquery/src/callbacks.js +119 -90
- data/bower_components/jquery/src/core.js +108 -134
- data/bower_components/jquery/src/core/DOMEval.js +16 -0
- data/bower_components/jquery/src/core/access.js +21 -11
- data/bower_components/jquery/src/core/init.js +33 -28
- data/bower_components/jquery/src/core/nodeName.js +13 -0
- data/bower_components/jquery/src/core/parseHTML.js +39 -13
- data/bower_components/jquery/src/core/ready-no-deferred.js +96 -0
- data/bower_components/jquery/src/core/ready.js +40 -51
- data/bower_components/jquery/src/core/readyException.js +13 -0
- data/bower_components/jquery/src/core/stripAndCollapse.js +14 -0
- data/bower_components/jquery/src/core/support.js +20 -0
- data/bower_components/jquery/src/core/var/rsingleTag.js +5 -3
- data/bower_components/jquery/src/css.js +146 -158
- data/bower_components/jquery/src/css/addGetHookIf.js +7 -3
- data/bower_components/jquery/src/css/adjustCSS.js +71 -0
- data/bower_components/jquery/src/css/curCSS.js +22 -14
- data/bower_components/jquery/src/css/hiddenVisibleSelectors.js +8 -8
- data/bower_components/jquery/src/css/showHide.js +105 -0
- data/bower_components/jquery/src/css/support.js +69 -76
- data/bower_components/jquery/src/css/var/cssExpand.js +4 -2
- data/bower_components/jquery/src/css/var/getStyles.js +11 -6
- data/bower_components/jquery/src/css/var/isHiddenWithinTree.js +34 -0
- data/bower_components/jquery/src/css/var/rmargin.js +5 -3
- data/bower_components/jquery/src/css/var/rnumnonpx.js +4 -2
- data/bower_components/jquery/src/css/{swap.js → var/swap.js} +5 -7
- data/bower_components/jquery/src/data.js +67 -66
- data/bower_components/jquery/src/data/Data.js +87 -107
- data/bower_components/jquery/src/data/{accepts.js → var/acceptData.js} +6 -7
- data/bower_components/jquery/src/data/var/{data_priv.js → dataPriv.js} +4 -2
- data/bower_components/jquery/src/data/var/{data_user.js → dataUser.js} +4 -2
- data/bower_components/jquery/src/deferred.js +314 -72
- data/bower_components/jquery/src/deferred/exceptionHook.js +21 -0
- data/bower_components/jquery/src/deprecated.js +36 -9
- data/bower_components/jquery/src/dimensions.js +16 -10
- data/bower_components/jquery/src/effects.js +257 -206
- data/bower_components/jquery/src/effects/Tween.js +18 -9
- data/bower_components/jquery/src/effects/animatedSelector.js +7 -5
- data/bower_components/jquery/src/event.js +297 -419
- data/bower_components/jquery/src/event/ajax.js +13 -4
- data/bower_components/jquery/src/event/alias.js +13 -23
- data/bower_components/jquery/src/event/focusin.js +55 -0
- data/bower_components/jquery/src/event/support.js +5 -3
- data/bower_components/jquery/src/event/trigger.js +185 -0
- data/bower_components/jquery/src/exports/amd.js +5 -3
- data/bower_components/jquery/src/exports/global.js +8 -6
- data/bower_components/jquery/src/jquery.js +6 -2
- data/bower_components/jquery/src/manipulation.js +218 -310
- data/bower_components/jquery/src/manipulation/_evalUrl.js +9 -4
- data/bower_components/jquery/src/manipulation/buildFragment.js +104 -0
- data/bower_components/jquery/src/manipulation/getAll.js +32 -0
- data/bower_components/jquery/src/manipulation/setGlobalEval.js +22 -0
- data/bower_components/jquery/src/manipulation/support.js +11 -8
- data/bower_components/jquery/src/manipulation/var/rcheckableType.js +5 -3
- data/bower_components/jquery/src/manipulation/var/rscriptType.js +5 -0
- data/bower_components/jquery/src/manipulation/var/rtagName.js +5 -0
- data/bower_components/jquery/src/manipulation/wrapMap.js +29 -0
- data/bower_components/jquery/src/offset.js +75 -53
- data/bower_components/jquery/src/queue.js +26 -23
- data/bower_components/jquery/src/queue/delay.js +8 -6
- data/bower_components/jquery/src/selector-native.js +133 -68
- data/bower_components/jquery/src/selector-sizzle.js +10 -5
- data/bower_components/jquery/src/selector.js +3 -1
- data/bower_components/jquery/src/serialize.js +52 -33
- data/bower_components/jquery/src/traversing.js +61 -69
- data/bower_components/jquery/src/traversing/findFilter.js +37 -31
- data/bower_components/jquery/src/traversing/var/dir.js +22 -0
- data/bower_components/jquery/src/traversing/var/rneedsContext.js +4 -2
- data/bower_components/jquery/src/traversing/var/siblings.js +17 -0
- data/bower_components/jquery/src/var/ObjectFunctionString.js +7 -0
- data/bower_components/jquery/src/var/arr.js +4 -2
- data/bower_components/jquery/src/var/class2type.js +4 -2
- data/bower_components/jquery/src/var/concat.js +4 -2
- data/bower_components/jquery/src/var/document.js +5 -0
- data/bower_components/jquery/src/var/documentElement.js +7 -0
- data/bower_components/jquery/src/var/fnToString.js +7 -0
- data/bower_components/jquery/src/var/getProto.js +5 -0
- data/bower_components/jquery/src/var/hasOwn.js +4 -2
- data/bower_components/jquery/src/var/indexOf.js +4 -2
- data/bower_components/jquery/src/var/pnum.js +5 -3
- data/bower_components/jquery/src/var/push.js +4 -2
- data/bower_components/jquery/src/var/rcssNum.js +9 -0
- data/bower_components/jquery/src/var/rnothtmlwhite.js +8 -0
- data/bower_components/jquery/src/var/slice.js +4 -2
- data/bower_components/jquery/src/var/support.js +4 -2
- data/bower_components/jquery/src/var/toString.js +4 -2
- data/bower_components/jquery/src/wrap.js +24 -26
- data/bower_components/leaflet-providers/.bower.json +6 -7
- data/bower_components/leaflet-providers/CHANGELOG.md +62 -0
- data/bower_components/leaflet-providers/README.md +12 -3
- data/bower_components/leaflet-providers/bower.json +1 -1
- data/bower_components/leaflet-providers/leaflet-providers.js +133 -92
- data/bower_components/leaflet-providers/package.json +14 -7
- data/bower_components/leaflet/.bower.json +10 -14
- data/bower_components/leaflet/CHANGELOG.md +648 -3
- data/bower_components/leaflet/CONTRIBUTING.md +88 -33
- data/bower_components/leaflet/ISSUE_TEMPLATE.md +25 -0
- data/bower_components/leaflet/Jakefile.js +73 -14
- data/bower_components/leaflet/LICENSE +1 -1
- data/bower_components/leaflet/PLUGIN-GUIDE.md +97 -3
- data/bower_components/leaflet/README.md +6 -8
- data/bower_components/leaflet/bower.json +3 -9
- data/bower_components/leaflet/dist/images/layers-2x.png +0 -0
- data/bower_components/leaflet/dist/images/layers.png +0 -0
- data/bower_components/leaflet/dist/images/marker-icon-2x.png +0 -0
- data/bower_components/leaflet/dist/images/marker-icon.png +0 -0
- data/bower_components/leaflet/dist/images/marker-shadow.png +0 -0
- data/bower_components/leaflet/dist/leaflet-src.js +12301 -7898
- data/bower_components/leaflet/dist/leaflet-src.js.map +1 -0
- data/bower_components/leaflet/dist/leaflet.css +196 -43
- data/bower_components/leaflet/dist/leaflet.js +6 -9
- data/bower_components/leaflet/dist/leaflet.js.map +1 -0
- data/bower_components/leaflet/docs/CNAME +1 -0
- data/bower_components/leaflet/docs/Gemfile +4 -0
- data/bower_components/leaflet/docs/_config.yml +19 -0
- data/bower_components/leaflet/docs/_includes/frame.html +9 -0
- data/bower_components/leaflet/docs/_includes/tutorial_link.html +8 -0
- data/bower_components/leaflet/docs/_layouts/post.html +30 -0
- data/bower_components/leaflet/docs/_layouts/redirected.html +14 -0
- data/bower_components/leaflet/docs/_layouts/tutorial.html +9 -0
- data/bower_components/leaflet/docs/_layouts/tutorial_frame.html +32 -0
- data/bower_components/leaflet/docs/_layouts/tutorial_v2.html +9 -0
- data/bower_components/leaflet/docs/_layouts/v2.html +159 -0
- data/bower_components/leaflet/docs/_posts/2012-07-30-leaflet-0-4-released.md +240 -0
- data/bower_components/leaflet/docs/_posts/2012-08-07-leaflet-0-4-3-and-a-new-tutorial.md +47 -0
- data/bower_components/leaflet/docs/_posts/2012-08-20-guest-post-markerclusterer-0-1-released.md +112 -0
- data/bower_components/leaflet/docs/_posts/2012-10-25-leaflet-0-4-5-bugfix-release-and-plans-for-0.5.md +36 -0
- data/bower_components/leaflet/docs/_posts/2013-01-17-leaflet-0-5-released.md +24 -0
- data/bower_components/leaflet/docs/_posts/2013-02-20-guest-post-draw.md +146 -0
- data/bower_components/leaflet/docs/_posts/2013-06-26-leaflet-0-6-released-dc-code-sprint-mapbox.md +31 -0
- data/bower_components/leaflet/docs/_posts/2013-06-28-leaflet-plugin-authoring-guide.md +111 -0
- data/bower_components/leaflet/docs/_posts/2013-11-18-leaflet-0-7-released-plans-for-future.md +56 -0
- data/bower_components/leaflet/docs/_posts/2015-07-01-leaflet-is-alive-and-kicking.md +21 -0
- data/bower_components/leaflet/docs/_posts/2015-07-15-leaflet-1.0-beta1-released.md +60 -0
- data/bower_components/leaflet/docs/_posts/2015-09-01-leaflet-0.7.4-released.md +29 -0
- data/bower_components/leaflet/docs/_posts/2015-10-14-leaflet-1.0-beta2-released.md +35 -0
- data/bower_components/leaflet/docs/_posts/2016-03-20-debugging-touch-interactions.md +101 -0
- data/bower_components/leaflet/docs/_posts/2016-04-18-leaflet-1.0-rc1.md +78 -0
- data/bower_components/leaflet/docs/_posts/2016-07-16-leaflet-1.0-rc2.md +60 -0
- data/bower_components/leaflet/docs/_posts/2016-08-05-leaflet-1.0-rc3.md +53 -0
- data/bower_components/leaflet/docs/_posts/2016-09-27-leaflet-1.0-final.md +50 -0
- data/bower_components/leaflet/docs/_posts/2016-11-21-leaflet-1.0.2.md +25 -0
- data/bower_components/leaflet/docs/_posts/2017-01-23-leaflet-1.0.3.md +27 -0
- data/bower_components/leaflet/docs/atom.xml +29 -0
- data/bower_components/leaflet/docs/blog.md +24 -0
- data/bower_components/leaflet/docs/docs/css/main.css +1092 -0
- data/bower_components/leaflet/docs/docs/css/normalize.css +426 -0
- data/bower_components/leaflet/docs/docs/highlight/LICENSE +24 -0
- data/bower_components/leaflet/docs/docs/highlight/highlight.pack.js +1 -0
- data/bower_components/leaflet/docs/docs/highlight/styles/github-gist.css +211 -0
- data/bower_components/leaflet/docs/docs/images/2016-03-20-prosthetic-hand-zooming.gif +0 -0
- data/bower_components/leaflet/docs/docs/images/2016-04-18-inheritances.gif +0 -0
- data/bower_components/leaflet/docs/docs/images/2016-04-18-leaflet-toilet-paper.jpeg +0 -0
- data/bower_components/leaflet/docs/docs/images/2016-04-18-madrid-leaflet-864px.jpg +0 -0
- data/bower_components/leaflet/docs/docs/images/2016-07-18-remote-session.png +0 -0
- data/bower_components/leaflet/docs/docs/images/2016-07-18-tooltip.png +0 -0
- data/bower_components/leaflet/docs/docs/images/2016-08-03-iraq-hacking.jpg +0 -0
- data/bower_components/leaflet/docs/docs/images/favicon.ico +0 -0
- data/bower_components/leaflet/docs/docs/images/forum-round.png +0 -0
- data/bower_components/leaflet/docs/docs/images/github-round.png +0 -0
- data/bower_components/leaflet/docs/docs/images/logo.png +0 -0
- data/bower_components/leaflet/docs/docs/images/logos.png +0 -0
- data/bower_components/leaflet/docs/docs/images/sprite.png +0 -0
- data/bower_components/leaflet/docs/docs/images/sprite.svg +75 -0
- data/bower_components/leaflet/docs/docs/images/twitter-round.png +0 -0
- data/bower_components/leaflet/docs/docs/images/twitter.png +0 -0
- data/bower_components/leaflet/docs/docs/js/docs.js +52 -0
- data/bower_components/leaflet/docs/download.md +95 -0
- data/bower_components/leaflet/docs/examples.md +125 -0
- data/bower_components/leaflet/docs/examples/choropleth-example.md +5 -0
- data/bower_components/leaflet/docs/examples/choropleth.md +5 -0
- data/bower_components/leaflet/docs/examples/choropleth/example-basic.md +20 -0
- data/bower_components/leaflet/docs/examples/choropleth/example-color.md +46 -0
- data/bower_components/leaflet/docs/examples/choropleth/example.md +159 -0
- data/bower_components/leaflet/docs/examples/choropleth/index.md +232 -0
- data/bower_components/leaflet/docs/examples/choropleth/thumbnail.png +0 -0
- data/bower_components/leaflet/docs/examples/choropleth/us-states.js +54 -0
- data/bower_components/leaflet/docs/examples/crs-simple/crs-simple-example1.md +16 -0
- data/bower_components/leaflet/docs/examples/crs-simple/crs-simple-example2.md +20 -0
- data/bower_components/leaflet/docs/examples/crs-simple/crs-simple-example3.md +38 -0
- data/bower_components/leaflet/docs/examples/crs-simple/crs-simple.md +117 -0
- data/bower_components/leaflet/docs/examples/crs-simple/thumbnail.png +0 -0
- data/bower_components/leaflet/docs/examples/crs-simple/uqm_map_400px.png +0 -0
- data/bower_components/leaflet/docs/examples/crs-simple/uqm_map_detail.png +0 -0
- data/bower_components/leaflet/docs/examples/crs-simple/uqm_map_full.png +0 -0
- data/bower_components/leaflet/docs/examples/custom-icons-example.md +5 -0
- data/bower_components/leaflet/docs/examples/custom-icons.md +5 -0
- data/bower_components/leaflet/docs/examples/custom-icons/example-one-icon.md +27 -0
- data/bower_components/leaflet/docs/examples/custom-icons/example.md +31 -0
- data/bower_components/leaflet/docs/examples/custom-icons/index.md +79 -0
- data/bower_components/leaflet/docs/examples/custom-icons/leaf-green.png +0 -0
- data/bower_components/leaflet/docs/examples/custom-icons/leaf-orange.png +0 -0
- data/bower_components/leaflet/docs/examples/custom-icons/leaf-red.png +0 -0
- data/bower_components/leaflet/docs/examples/custom-icons/leaf-shadow.png +0 -0
- data/bower_components/leaflet/docs/examples/custom-icons/thumbnail.png +0 -0
- data/bower_components/leaflet/docs/examples/extending/canvascircles.md +37 -0
- data/bower_components/leaflet/docs/examples/extending/class-diagram.md +24 -0
- data/bower_components/leaflet/docs/examples/extending/class-diagram.png +0 -0
- data/bower_components/leaflet/docs/examples/extending/class-diagram.txt +100 -0
- data/bower_components/leaflet/docs/examples/extending/extending-1-classes.md +196 -0
- data/bower_components/leaflet/docs/examples/extending/extending-2-layers.md +210 -0
- data/bower_components/leaflet/docs/examples/extending/extending-3-controls.md +100 -0
- data/bower_components/leaflet/docs/examples/extending/gridcoords.md +32 -0
- data/bower_components/leaflet/docs/examples/extending/kittenlayer.md +29 -0
- data/bower_components/leaflet/docs/examples/extending/pixelorigin.md +90 -0
- data/bower_components/leaflet/docs/examples/extending/thumbnail-1.png +0 -0
- data/bower_components/leaflet/docs/examples/extending/thumbnail-2.png +0 -0
- data/bower_components/leaflet/docs/examples/extending/thumbnail-3.png +0 -0
- data/bower_components/leaflet/docs/examples/extending/tilt.md +59 -0
- data/bower_components/leaflet/docs/examples/extending/watermark.md +36 -0
- data/bower_components/leaflet/docs/examples/geojson-example.md +5 -0
- data/bower_components/leaflet/docs/examples/geojson.md +5 -0
- data/bower_components/leaflet/docs/examples/geojson/baseball-marker.png +0 -0
- data/bower_components/leaflet/docs/examples/geojson/example.md +78 -0
- data/bower_components/leaflet/docs/examples/geojson/geojson-example.html +89 -0
- data/bower_components/leaflet/docs/examples/geojson/geojson.html +281 -0
- data/bower_components/leaflet/docs/examples/geojson/index.md +205 -0
- data/bower_components/leaflet/docs/examples/geojson/sample-geojson.js +248 -0
- data/bower_components/leaflet/docs/examples/geojson/thumbnail.png +0 -0
- data/bower_components/leaflet/docs/examples/layers-control-example.md +5 -0
- data/bower_components/leaflet/docs/examples/layers-control.md +5 -0
- data/bower_components/leaflet/docs/examples/layers-control/example.md +38 -0
- data/bower_components/leaflet/docs/examples/layers-control/index.md +72 -0
- data/bower_components/leaflet/docs/examples/layers-control/thumbnail.png +0 -0
- data/bower_components/leaflet/docs/examples/map-panes-example.md +5 -0
- data/bower_components/leaflet/docs/examples/map-panes.md +5 -0
- data/bower_components/leaflet/docs/examples/map-panes/eu-countries.js +79 -0
- data/bower_components/leaflet/docs/examples/map-panes/example.md +38 -0
- data/bower_components/leaflet/docs/examples/map-panes/index.md +105 -0
- data/bower_components/leaflet/docs/examples/map-panes/thumbnail.png +0 -0
- data/bower_components/leaflet/docs/examples/mobile-example.md +5 -0
- data/bower_components/leaflet/docs/examples/mobile.md +5 -0
- data/bower_components/leaflet/docs/examples/mobile/example.md +42 -0
- data/bower_components/leaflet/docs/examples/mobile/index.md +72 -0
- data/bower_components/leaflet/docs/examples/mobile/thumbnail.png +0 -0
- data/bower_components/leaflet/docs/examples/quick-start-example.md +5 -0
- data/bower_components/leaflet/docs/examples/quick-start.md +5 -0
- data/bower_components/leaflet/docs/examples/quick-start/example-basic.md +19 -0
- data/bower_components/leaflet/docs/examples/quick-start/example-overlays.md +35 -0
- data/bower_components/leaflet/docs/examples/quick-start/example-popups.md +37 -0
- data/bower_components/leaflet/docs/examples/quick-start/example.md +46 -0
- data/bower_components/leaflet/docs/examples/quick-start/index.md +143 -0
- data/bower_components/leaflet/docs/examples/quick-start/thumbnail.png +0 -0
- data/bower_components/leaflet/docs/examples/video-overlay/example-bounds.md +23 -0
- data/bower_components/leaflet/docs/examples/video-overlay/example-nocontrols.md +31 -0
- data/bower_components/leaflet/docs/examples/video-overlay/example.md +58 -0
- data/bower_components/leaflet/docs/examples/video-overlay/index.md +122 -0
- data/bower_components/leaflet/docs/examples/video-overlay/thumbnail.gif +0 -0
- data/bower_components/leaflet/docs/examples/wms/qgis-wms-layers.png +0 -0
- data/bower_components/leaflet/docs/examples/wms/thumbnail.png +0 -0
- data/bower_components/leaflet/docs/examples/wms/wms-example-crs.md +18 -0
- data/bower_components/leaflet/docs/examples/wms/wms-example1.md +16 -0
- data/bower_components/leaflet/docs/examples/wms/wms-example2.md +16 -0
- data/bower_components/leaflet/docs/examples/wms/wms-example3.md +34 -0
- data/bower_components/leaflet/docs/examples/wms/wms-example4.md +29 -0
- data/bower_components/leaflet/docs/examples/wms/wms.md +157 -0
- data/bower_components/leaflet/docs/examples/zoom-levels/example-delta.md +40 -0
- data/bower_components/leaflet/docs/examples/zoom-levels/example-fractional.md +56 -0
- data/bower_components/leaflet/docs/examples/zoom-levels/example-scale.md +29 -0
- data/bower_components/leaflet/docs/examples/zoom-levels/example-setzoom.md +44 -0
- data/bower_components/leaflet/docs/examples/zoom-levels/example-zero.md +19 -0
- data/bower_components/leaflet/docs/examples/zoom-levels/index.md +275 -0
- data/bower_components/leaflet/docs/examples/zoom-levels/thumbnail.png +0 -0
- data/bower_components/leaflet/docs/index.html +218 -0
- data/bower_components/leaflet/docs/plugins.md +3854 -0
- data/bower_components/leaflet/docs/reference-0.7.7.html +6424 -0
- data/bower_components/leaflet/docs/reference-1.0.0.html +22889 -0
- data/bower_components/leaflet/docs/reference-1.0.2.html +23382 -0
- data/bower_components/leaflet/docs/reference-1.0.3.html +23495 -0
- data/bower_components/leaflet/docs/reference-tpl.html +89 -0
- data/bower_components/leaflet/docs/reference-versions.html +16 -0
- data/bower_components/leaflet/docs/reference.html +3 -0
- data/bower_components/leaflet/package.json +77 -16
- data/columbus3.gemspec +1 -1
- data/doc/ChangeLog.org +10 -0
- data/doc/manual.txt +122 -0
- data/doc/todo.org +63 -0
- data/exe/columbus3 +2 -246
- data/lib/columbus3.rb +12 -7
- data/lib/columbus3/cli/command_semantics.rb +352 -0
- data/lib/columbus3/cli/command_syntax.rb +103 -0
- data/lib/columbus3/metadata/query_parser.racc +21 -7
- data/lib/columbus3/metadata/query_parser.tab.rb +34 -34
- data/lib/columbus3/metadata/sidecar.rb +1 -1
- data/lib/columbus3/renderer/flot_renderer.rb +3 -8
- data/lib/columbus3/renderer/leaflet_renderer.rb +18 -29
- data/lib/columbus3/renderer/sanitizer.rb +8 -0
- data/lib/columbus3/v900track/gpx2v900.rb +31 -0
- data/lib/columbus3/v900track/v900track.rb +34 -8
- data/lib/columbus3/v900track/v900waypoint.rb +9 -0
- data/lib/columbus3/version.rb +1 -1
- data/lib/html/flot.html.erb +6 -6
- data/lib/html/show.html.erb +53 -76
- data/lib/html/track.js.erb +58 -12
- metadata +222 -23
- data/README.textile +0 -67
- data/bower_components/jquery/src/ajax/parseJSON.js +0 -13
- data/bower_components/jquery/src/css/defaultDisplay.js +0 -70
- data/bower_components/jquery/src/css/var/isHidden.js +0 -13
- data/bower_components/jquery/src/intro.js +0 -44
- data/bower_components/jquery/src/outro.js +0 -1
- data/bower_components/jquery/src/sizzle/dist/sizzle.min.js +0 -3
- data/bower_components/jquery/src/sizzle/dist/sizzle.min.map +0 -1
- data/bower_components/jquery/src/var/rnotwhite.js +0 -3
- data/bower_components/jquery/src/var/strundefined.js +0 -3
- data/bower_components/leaflet/component.json +0 -20
@@ -0,0 +1,89 @@
|
|
1
|
+
<!-- Snippets to use for docs -->
|
2
|
+
|
3
|
+
<!-- Argument -->
|
4
|
+
|
5
|
+
<nobr><<a href="#foo">Foo</a>> <i>name</i></nobr>
|
6
|
+
|
7
|
+
|
8
|
+
<!-- Class -->
|
9
|
+
|
10
|
+
<h2 id="[class-anchor]">[class-name]</h2>
|
11
|
+
|
12
|
+
<p>[description]</p>
|
13
|
+
|
14
|
+
<pre><code>[code-example]</code></pre>
|
15
|
+
|
16
|
+
|
17
|
+
<!-- constructor -->
|
18
|
+
|
19
|
+
<h3>Constructor</h3>
|
20
|
+
|
21
|
+
<table>
|
22
|
+
<tr>
|
23
|
+
<th>Constructor</th>
|
24
|
+
<th>Usage</th>
|
25
|
+
<th>Description</th>
|
26
|
+
</tr>
|
27
|
+
<tr>
|
28
|
+
<td><code>[constructor]( [arguments] )</code></td>
|
29
|
+
<td class="factory-usage">
|
30
|
+
<code><span class='keyword'>new</span> L.Map(<span class="comment">…</span>)</code><br />
|
31
|
+
<code>L.map(<span class="comment">…</span>)</code>
|
32
|
+
</td>
|
33
|
+
<td>[description]</td>
|
34
|
+
</tr>
|
35
|
+
</table>
|
36
|
+
|
37
|
+
|
38
|
+
<!-- methods -->
|
39
|
+
|
40
|
+
<h3>Methods</h3>
|
41
|
+
<table>
|
42
|
+
<tr>
|
43
|
+
<th>Method</th>
|
44
|
+
<th>Returns</th>
|
45
|
+
<th>Description</th>
|
46
|
+
</tr>
|
47
|
+
<tr>
|
48
|
+
<td><code><b>[method]</b>(<nobr><type></nobr> <i>argument</i>, <nobr><type> <i>argument</i>)</nobr></code></td>
|
49
|
+
<td><code>[return-type]</code></td>
|
50
|
+
<td>[description]</td>
|
51
|
+
</tr>
|
52
|
+
</table>
|
53
|
+
|
54
|
+
|
55
|
+
<!-- options -->
|
56
|
+
|
57
|
+
<h3 id="[class-anchor]-options">Options</h3>
|
58
|
+
|
59
|
+
<table>
|
60
|
+
<tr>
|
61
|
+
<th>Option</th>
|
62
|
+
<th>Type</th>
|
63
|
+
<th>Default value</th>
|
64
|
+
<th>Description</th>
|
65
|
+
</tr>
|
66
|
+
<tr>
|
67
|
+
<td><code><b>[name]</b></code></td>
|
68
|
+
<td><code>[type]</code></td>
|
69
|
+
<td><code>[default]</code></td>
|
70
|
+
<td>[description]</td>
|
71
|
+
</tr>
|
72
|
+
</table>
|
73
|
+
|
74
|
+
<!-- events -->
|
75
|
+
|
76
|
+
<h3>Events</h3>
|
77
|
+
|
78
|
+
<table>
|
79
|
+
<tr>
|
80
|
+
<th>Event</th>
|
81
|
+
<th>Data</th>
|
82
|
+
<th>Description</th>
|
83
|
+
</tr>
|
84
|
+
<tr>
|
85
|
+
<td><code><b>[name]</b></code></td>
|
86
|
+
<td><code><a href="[link]">[type]</a></code></td>
|
87
|
+
<td>[description]</td>
|
88
|
+
</tr>
|
89
|
+
</table>
|
@@ -0,0 +1,16 @@
|
|
1
|
+
---
|
2
|
+
layout: v2
|
3
|
+
title: Documentation
|
4
|
+
bodyclass: api-page
|
5
|
+
---
|
6
|
+
|
7
|
+
<h2>Available API References</h2>
|
8
|
+
|
9
|
+
<p>This page lists the API references for several Leaflet versions.</p>
|
10
|
+
|
11
|
+
<p><ul>
|
12
|
+
<li><a href='reference-0.7.7.html'>API reference for 0.7.x</a>
|
13
|
+
<li><a href='reference-1.0.0.html'>API reference for 1.0.0 and 1.0.1</a>
|
14
|
+
<li><a href='reference-1.0.2.html'>API reference for 1.0.2</a>
|
15
|
+
<li><a href='reference-1.0.3.html'>API reference for 1.0.3</a>
|
16
|
+
</ul></p>
|
@@ -1,26 +1,86 @@
|
|
1
1
|
{
|
2
2
|
"name": "leaflet",
|
3
|
-
"version": "
|
3
|
+
"version": "1.1.0",
|
4
4
|
"description": "JavaScript library for mobile-friendly interactive maps",
|
5
5
|
"devDependencies": {
|
6
|
-
"
|
7
|
-
"
|
8
|
-
"
|
9
|
-
"
|
10
|
-
"
|
11
|
-
"karma": "
|
12
|
-
"karma-
|
13
|
-
"karma-coverage": "~
|
14
|
-
"karma-
|
15
|
-
"karma-
|
16
|
-
"
|
17
|
-
"
|
6
|
+
"eslint": "^3.5.0 <3.6.0",
|
7
|
+
"eslint-config-mourner": "^2.0.1",
|
8
|
+
"git-rev-sync": "^1.8.0",
|
9
|
+
"happen": "~0.3.1",
|
10
|
+
"jake": "~8.0.12",
|
11
|
+
"karma": "^1.3.0",
|
12
|
+
"karma-chrome-launcher": "^2.0.0",
|
13
|
+
"karma-coverage": "~1.1.1",
|
14
|
+
"karma-firefox-launcher": "~1.0.0",
|
15
|
+
"karma-mocha": "^1.2.0",
|
16
|
+
"karma-phantomjs-launcher": "^1.0.2",
|
17
|
+
"karma-rollup-plugin": "^0.2.4",
|
18
|
+
"karma-safari-launcher": "~1.0.0",
|
19
|
+
"leafdoc": "^1.4.1",
|
20
|
+
"mocha": "^3.1.0",
|
21
|
+
"phantomjs-prebuilt": "^2.1.12",
|
22
|
+
"prosthetic-hand": "^1.3.1",
|
23
|
+
"rollup": "^0.41.4",
|
24
|
+
"rollup-plugin-git-version": "0.2.1",
|
25
|
+
"rollup-plugin-json": "^2.1.0",
|
26
|
+
"rollup-watch": "^2.5.0",
|
27
|
+
"source-map": "^0.5.6",
|
28
|
+
"ssri": "^4.1.2",
|
29
|
+
"uglify-js": "~2.7.3"
|
18
30
|
},
|
19
31
|
"main": "dist/leaflet-src.js",
|
32
|
+
"style": "dist/leaflet.css",
|
20
33
|
"scripts": {
|
34
|
+
"test-jake": "jake test",
|
21
35
|
"test": "jake test",
|
22
|
-
"
|
23
|
-
"
|
36
|
+
"build-jake": "jake build",
|
37
|
+
"build": "npm run rollup && npm run uglify",
|
38
|
+
"release": "./build/publish.sh",
|
39
|
+
"lint": "eslint src; eslint spec/suites",
|
40
|
+
"lintfix": "eslint src --fix; eslint spec/suites --fix; ",
|
41
|
+
"rollup": "rollup -c build/rollup-config.js",
|
42
|
+
"watch": "rollup -w -c build/rollup-watch-config.js",
|
43
|
+
"uglify": "uglifyjs dist/leaflet-src.js -c -m -o dist/leaflet.js --source-map dist/leaflet.js.map --in-source-map dist/leaflet-src.js.map --source-map-url leaflet.js.map",
|
44
|
+
"integrity": "nodejs ./build/integrity.js"
|
45
|
+
},
|
46
|
+
"eslintConfig": {
|
47
|
+
"root": true,
|
48
|
+
"globals": {
|
49
|
+
"L": true
|
50
|
+
},
|
51
|
+
"env": {
|
52
|
+
"commonjs": true,
|
53
|
+
"amd": true,
|
54
|
+
"node": false
|
55
|
+
},
|
56
|
+
"extends": "mourner",
|
57
|
+
"parserOptions": {
|
58
|
+
"ecmaVersion": 6,
|
59
|
+
"sourceType": "module"
|
60
|
+
},
|
61
|
+
"rules": {
|
62
|
+
"linebreak-style": [
|
63
|
+
0,
|
64
|
+
"unix"
|
65
|
+
],
|
66
|
+
"no-mixed-spaces-and-tabs": [
|
67
|
+
2,
|
68
|
+
"smart-tabs"
|
69
|
+
],
|
70
|
+
"indent": [
|
71
|
+
2,
|
72
|
+
"tab",
|
73
|
+
{
|
74
|
+
"VariableDeclarator": 0
|
75
|
+
}
|
76
|
+
],
|
77
|
+
"curly": 2,
|
78
|
+
"spaced-comment": 2,
|
79
|
+
"strict": 0,
|
80
|
+
"wrap-iife": 0,
|
81
|
+
"key-spacing": 0,
|
82
|
+
"consistent-return": 0
|
83
|
+
}
|
24
84
|
},
|
25
85
|
"repository": {
|
26
86
|
"type": "git",
|
@@ -29,5 +89,6 @@
|
|
29
89
|
"keywords": [
|
30
90
|
"gis",
|
31
91
|
"map"
|
32
|
-
]
|
92
|
+
],
|
93
|
+
"license": "BSD-2-Clause"
|
33
94
|
}
|
data/columbus3.gemspec
CHANGED
data/doc/ChangeLog.org
ADDED
@@ -0,0 +1,10 @@
|
|
1
|
+
Archived entries from file /home/adolfo/Documents/Sources/ruby/columbus3/doc/todo.org
|
2
|
+
|
3
|
+
* DONE GPX import
|
4
|
+
:PROPERTIES:
|
5
|
+
:ARCHIVE_TIME: 2017-07-26 Wed 15:15
|
6
|
+
:ARCHIVE_FILE: ~/Documents/Sources/ruby/columbus3/doc/todo.org
|
7
|
+
:ARCHIVE_OLPATH: Rails: columbus3
|
8
|
+
:ARCHIVE_CATEGORY: todo
|
9
|
+
:ARCHIVE_TODO: DONE
|
10
|
+
:END:
|
data/doc/manual.txt
ADDED
@@ -0,0 +1,122 @@
|
|
1
|
+
NAME
|
2
|
+
columbus3 -- manage Columbus V900 and V990 tracks from the command line
|
3
|
+
|
4
|
+
SYNOPSYS
|
5
|
+
columbus3 [-h|-v]
|
6
|
+
columbus3 command [options] [args]
|
7
|
+
|
8
|
+
DESCRIPTION
|
9
|
+
|
10
|
+
columbus3 manages Columbus V900 and V990 tracks from the command line,
|
11
|
+
allowing a user to associate a sidecar file with the main information
|
12
|
+
about a track, searching tracks (through sidecar files), displaying
|
13
|
+
tracks on a map.
|
14
|
+
|
15
|
+
EXAMPLES
|
16
|
+
|
17
|
+
columbus3 -h # get syntax of each command
|
18
|
+
columbus3 process 11010101.CSV # generate a sidecar file
|
19
|
+
columbus3 search 'location ~ "USA"' # get tracks in the USA
|
20
|
+
columbus3 show 11010101.CSV 11010201.CSV # show tracks on a map (_show.html)
|
21
|
+
columbus3 graph 11010101.CSV # show info about a track (_graph.html)
|
22
|
+
|
23
|
+
if you do not want to type columbus3 each type, you can invoke a console:
|
24
|
+
|
25
|
+
columbus3 console
|
26
|
+
columbus3:000> process 11010101.CSV
|
27
|
+
columbus3:001> show 11010101.CSV
|
28
|
+
columbus3:002>
|
29
|
+
|
30
|
+
columbus3 also has a function to convert a GPX into a bunch of CSV
|
31
|
+
files (which you can then process with the other commands), with some
|
32
|
+
limitations (see below).
|
33
|
+
|
34
|
+
The command is useful if you are using different loggers for generating your
|
35
|
+
tracks:
|
36
|
+
|
37
|
+
columbus3 convert file.gpx
|
38
|
+
|
39
|
+
will generate
|
40
|
+
|
41
|
+
file-1.csv
|
42
|
+
file-2.csv
|
43
|
+
...
|
44
|
+
|
45
|
+
one per track in the GPX file.
|
46
|
+
|
47
|
+
**CSV export limitations** The Columbus V900 format has fields with fixed width,
|
48
|
+
and uses ^@ as a filler. The CSV file generated by the convert command generates fields
|
49
|
+
of variable width (standard CSV files, I dare say). The heading field is not computed
|
50
|
+
and the field is filled with -1.
|
51
|
+
|
52
|
+
Piping commands. You can pipe the output of a search command to show, using
|
53
|
+
the following syntax:
|
54
|
+
|
55
|
+
columbus3 search 'location ~ "USA"' --fields path | columbus3 show --sidecar
|
56
|
+
|
57
|
+
The option --fields shows only the pathname of the files found; the option
|
58
|
+
--sidecar removes the .yaml extension from the list of files found.
|
59
|
+
|
60
|
+
SEARCH SYNTAX
|
61
|
+
|
62
|
+
>>> DON'T FORGET TO EMBED YOUR QUERY IN SINGLE QUOTES <<<
|
63
|
+
|
64
|
+
Terms you can search for:
|
65
|
+
|
66
|
+
location, start_location, end_location
|
67
|
+
date, start_date, end_date
|
68
|
+
year
|
69
|
+
duration
|
70
|
+
max_speed
|
71
|
+
min_height
|
72
|
+
max_height
|
73
|
+
|
74
|
+
Numerical operators:
|
75
|
+
<, <=, ==, >=, >
|
76
|
+
|
77
|
+
String operators (locations):
|
78
|
+
~ (contains), == (is exactly)
|
79
|
+
|
80
|
+
Complex Terms:
|
81
|
+
Use "and" and "or" to build complex queries
|
82
|
+
|
83
|
+
Examples of simple searches
|
84
|
+
'location ~ "USA"' any track whose start or end location contains USA
|
85
|
+
'date > 2015-02-14' any track whose start or end date is after Feb 14, 2015
|
86
|
+
'year == 2015' any track whose start or end date is in 2015
|
87
|
+
'duration <= 01:02:03' any track with a duration of less than 1h, 2min, and 3secs
|
88
|
+
'max_speed > 120' any track with a max speed greater than 120 km/h
|
89
|
+
'min_height == 10' any track with a min height lower than 10 meters
|
90
|
+
|
91
|
+
Examples of complex searches
|
92
|
+
'location ~ "USA" and start_date >= 2015-01-01' tracks in the USA after or on Jan 1, 2015
|
93
|
+
'start_location ~ "Trenton" and end_location ~ "New York"' trips from Trenton to New York
|
94
|
+
|
95
|
+
List of supported fields in output
|
96
|
+
path -> relative path of the CSV file
|
97
|
+
filename -> basename of the CSV file
|
98
|
+
start_location -> start location
|
99
|
+
end_location -> end location
|
100
|
+
start_date -> start date (and time)
|
101
|
+
end_date -> end date (and time)
|
102
|
+
duration -> duration in seconds
|
103
|
+
min_speed -> minimum speed in km/h
|
104
|
+
max_speed -> maximum speed in km/h
|
105
|
+
min_height -> minimum height in meters
|
106
|
+
max_height -> maximum height in meters
|
107
|
+
|
108
|
+
VERSION
|
109
|
+
This is version 0.5.0
|
110
|
+
|
111
|
+
LICENSE
|
112
|
+
MIT
|
113
|
+
|
114
|
+
Columbus3 uses leaflet, leafleft-providers, flot, and jquery. They
|
115
|
+
are distributed under a different license: see their websites for more
|
116
|
+
details (or have a look at the license file shipped with the Gem)
|
117
|
+
|
118
|
+
SEE ALSO
|
119
|
+
If you are looking for a full graphical client, you might want to
|
120
|
+
download Columbus from http://www.minimalbit.com
|
121
|
+
|
122
|
+
https://github.com/avillafiorita/columbus3
|
data/doc/todo.org
ADDED
@@ -0,0 +1,63 @@
|
|
1
|
+
#+TITLE: Columbus3 Todos
|
2
|
+
#+FILETAGS: :columbus3:
|
3
|
+
#+ARCHIVE: ChangeLog.org::
|
4
|
+
#+STARTUP: showall
|
5
|
+
|
6
|
+
* Rails: columbus3
|
7
|
+
** TODO integrate manual generation (manual.txt) in the deployment process
|
8
|
+
** FEATURE be more informative about what is going on
|
9
|
+
Many commands succeed silently. They could probably print some
|
10
|
+
informative messages
|
11
|
+
** FEATURE As a user I want to be able to view the individual points
|
12
|
+
Performance is an issue, here. Maybe activate the layer on a need-basis.
|
13
|
+
Also: it would be nice to produce a single GeoJSON set of data (e.g., the
|
14
|
+
point of a track and present it in different ways, e.g., line and points)
|
15
|
+
#+BEGIN_SRC ruby
|
16
|
+
<% @track.range.each do |i| %>
|
17
|
+
{ "type": "Feature",
|
18
|
+
"geometry": {
|
19
|
+
"type": "Point",
|
20
|
+
"coordinates": <%= @track[i].lon_lat %>
|
21
|
+
},
|
22
|
+
"properties": {
|
23
|
+
"index": <%= i %>,
|
24
|
+
"time": "<%= @track[i].time %>",
|
25
|
+
"speed": <%= @track[i].speed %>,
|
26
|
+
"height": <%= @track[i].height %>,
|
27
|
+
<% [:max_speed, :min_height, :max_height].each do |x| %>
|
28
|
+
<%= i == @track.send(x.to_s + "_idx") ? '"#{x}": "yes",' : ""%>
|
29
|
+
<% end %>
|
30
|
+
}
|
31
|
+
},
|
32
|
+
<% end %>
|
33
|
+
#+END_SRC
|
34
|
+
#+BEGIN_SRC javascript
|
35
|
+
pointToLayer: function (feature, latlng) {
|
36
|
+
if (feature.properties....)
|
37
|
+
return L.circleMarker(latlng, {
|
38
|
+
radius: 8,
|
39
|
+
fillColor: "#ff7800",
|
40
|
+
color: "#000",
|
41
|
+
weight: 1,
|
42
|
+
opacity: 1,
|
43
|
+
fillOpacity: 0.8
|
44
|
+
});
|
45
|
+
}
|
46
|
+
#+END_SRC
|
47
|
+
|
48
|
+
** FEATURE As a user I want to identify the time/index of individual points
|
49
|
+
This is useful for track splitting
|
50
|
+
** FEATURE As a user I want to have an idea of the direction and other info such as speed and height
|
51
|
+
Some possible solutions include: color dots, put height and speed plot on the same page)
|
52
|
+
** FEATURE As a user I want to split a track at point
|
53
|
+
Pass the index as argument and generate two files out of the existing one
|
54
|
+
Give the option to delete the old file and to process the new files
|
55
|
+
** FEATURE GPX export for DarkTable and GoogleEarth
|
56
|
+
** FEATURE As a user I want to be able to add custom fields
|
57
|
+
Allow users to specify custom fields in the sidecar file
|
58
|
+
** FEATURE As a user I want to filter values with wrong precision
|
59
|
+
** FEATURE As a user I do not want to view data only in ZULU time
|
60
|
+
- get the local timezone (or let the user specify a timezone)
|
61
|
+
- use the timezone of the starting point
|
62
|
+
** FEATURE Make it into a sinatra app?
|
63
|
+
|
data/exe/columbus3
CHANGED
@@ -1,249 +1,5 @@
|
|
1
1
|
#!/usr/bin/env ruby
|
2
2
|
|
3
|
-
require
|
4
|
-
require "columbus3"
|
5
|
-
require "find"
|
3
|
+
require 'columbus3'
|
6
4
|
|
7
|
-
|
8
|
-
version = Columbus3::VERSION
|
9
|
-
usage = "#{appname} [-h|-v]\n#{appname} command [options] [args]"
|
10
|
-
man = <<EOS
|
11
|
-
NAME
|
12
|
-
#{appname} -- manage Columbus V900 and V990 tracks from the command line
|
13
|
-
|
14
|
-
SYNOPSYS
|
15
|
-
#{appname} [-h|-v]
|
16
|
-
#{appname} command [options] [args]
|
17
|
-
|
18
|
-
DESCRIPTION
|
19
|
-
|
20
|
-
columbus3 manages Columbus V900 and V990 tracks from the command line,
|
21
|
-
allowing a user to associate a sidecar file with the main information
|
22
|
-
about a track, searching tracks (through sidecar files), displaying
|
23
|
-
tracks on a map.
|
24
|
-
|
25
|
-
EXAMPLES
|
26
|
-
#{appname} -h # get syntax of each command
|
27
|
-
columbus3 process 11010101.CSV # generate a sidecar file
|
28
|
-
columbus3 search 'location ~ "USA"' # track in the USA
|
29
|
-
columbus3 show 11010101.CSV 11010201.CSV # show tracks on a map (_show.html)
|
30
|
-
columbus3 graph 11010101.CSV # show info about a track (_graph.html)
|
31
|
-
|
32
|
-
SEARCH SYNTAX
|
33
|
-
|
34
|
-
>>> DON'T FORGET TO EMBED YOUR QUERY IN SINGLE QUOTES <<<
|
35
|
-
|
36
|
-
Terms you can search for:
|
37
|
-
location, start_location, end_location
|
38
|
-
date, start_date, end_date
|
39
|
-
year
|
40
|
-
duration
|
41
|
-
max_speed
|
42
|
-
min_height
|
43
|
-
max_height
|
44
|
-
|
45
|
-
Numerical operators:
|
46
|
-
<, <=, ==, >=, >
|
47
|
-
|
48
|
-
String operators (locations):
|
49
|
-
~ (contains), == (is exactly)
|
50
|
-
|
51
|
-
Complex Terms:
|
52
|
-
Use "and" and "or" to build complex queries
|
53
|
-
|
54
|
-
Examples of simple searches
|
55
|
-
'location ~ "USA"' any track whose start or end location contains USA
|
56
|
-
'date > 2015-02-14' any track whose start or end date is after Feb 14, 2015
|
57
|
-
'year == 2015' any track whose start or end date is in 2015
|
58
|
-
'duration <= 01:02:03' any track with a duration of less than 1h, 2min, and 3secs
|
59
|
-
'max_speed > 120' any track with a max speed greater than 120 km/h
|
60
|
-
'min_height == 10' any track with a min height lower than 10 meters
|
61
|
-
|
62
|
-
Examples of complex searches
|
63
|
-
'location ~ "USA" and start_date >= 2015-01-01' tracks in the USA after or on Jan 1, 2015
|
64
|
-
'start_location ~ "Trenton" and end_location ~ "New York"' trips from Trenton to New York
|
65
|
-
|
66
|
-
List of supported fields in output
|
67
|
-
path -> relative path of the CSV file
|
68
|
-
filename -> basename of the CSV file
|
69
|
-
start_location -> start location
|
70
|
-
end_location -> end location
|
71
|
-
start_date -> start date (and time)
|
72
|
-
end_date -> end date (and time)
|
73
|
-
duration -> duration in seconds
|
74
|
-
min_speed -> minimum speed in km/h
|
75
|
-
max_speed -> maximum speed in km/h
|
76
|
-
min_height -> minimum height in meters
|
77
|
-
max_height -> maximum height in meters
|
78
|
-
|
79
|
-
VERSION
|
80
|
-
This is version #{version}
|
81
|
-
|
82
|
-
LICENSE
|
83
|
-
MIT
|
84
|
-
|
85
|
-
Columbus3 uses leaflet, leafleft-providers, flot, and jquery. They
|
86
|
-
are distributed under a different license: see their websites for more
|
87
|
-
details (or have a look at the license file shipped with the Gem)
|
88
|
-
|
89
|
-
SEE ALSO
|
90
|
-
If you are looking for a full graphical client, you might want to
|
91
|
-
download Columbus from http://www.minimalbit.com
|
92
|
-
|
93
|
-
https://github.com/avillafiorita/columbus3
|
94
|
-
EOS
|
95
|
-
|
96
|
-
#
|
97
|
-
# Main App Starts Here!
|
98
|
-
#
|
99
|
-
cmd = nil
|
100
|
-
opts = Slop.parse :help => true do
|
101
|
-
banner usage
|
102
|
-
|
103
|
-
##############################################################################
|
104
|
-
on "-v", "--version", 'Print version information' do
|
105
|
-
cmd ="version"
|
106
|
-
puts "#{appname} version #{version}"
|
107
|
-
end
|
108
|
-
|
109
|
-
##############################################################################
|
110
|
-
command :man do
|
111
|
-
banner "#{appname} man"
|
112
|
-
description "Print man page for #{appname}"
|
113
|
-
|
114
|
-
run do |_, _|
|
115
|
-
cmd ="man"
|
116
|
-
puts man
|
117
|
-
end
|
118
|
-
end
|
119
|
-
|
120
|
-
##############################################################################
|
121
|
-
command :process do
|
122
|
-
banner "#{appname} process [--help] [track ...]"
|
123
|
-
description "Generate a sidecar file for the specified tracks"
|
124
|
-
|
125
|
-
on "--force", "Overwrite existing sidecar files"
|
126
|
-
|
127
|
-
run do |opts, args|
|
128
|
-
cmd ="process"
|
129
|
-
force = opts.to_hash[:force]
|
130
|
-
|
131
|
-
args.each do |arg|
|
132
|
-
track = V900Track.new arg
|
133
|
-
sidecar = Columbus3::Sidecar.new arg
|
134
|
-
if sidecar.exist? and not force
|
135
|
-
puts "Sidecar file for #{track} already exists. Use --force if you want to overwrite it."
|
136
|
-
else
|
137
|
-
sidecar.metadata = track.metadata
|
138
|
-
sidecar.save
|
139
|
-
end
|
140
|
-
end
|
141
|
-
end
|
142
|
-
end
|
143
|
-
|
144
|
-
##############################################################################
|
145
|
-
command :search do
|
146
|
-
banner "#{appname} search [--help] [-r] [--dir directory] [--fields fields] query"
|
147
|
-
description "Search dir for tracks matching query"
|
148
|
-
|
149
|
-
on "--debug", "Show how the query is processed"
|
150
|
-
on "-r", "--recurse", "Recurse in subdirectories"
|
151
|
-
on "-d", "--dir=", "Directory with sidecar files"
|
152
|
-
on "-fields=", "Comma separated list of fields to show"
|
153
|
-
|
154
|
-
run do |opts, args|
|
155
|
-
cmd ="search"
|
156
|
-
|
157
|
-
debug = opts.to_hash[:debug]
|
158
|
-
directory = opts.to_hash[:dir] || "."
|
159
|
-
recurse = opts.to_hash[:recurse]
|
160
|
-
fields_opt = opts.to_hash[:fields]
|
161
|
-
|
162
|
-
if fields? then
|
163
|
-
fields = fields_opt.split(",").map { |x| x.to_sym }
|
164
|
-
else
|
165
|
-
fields = [:path, :filename, :start_location, :end_location, :start_date, :end_date, :duration, :min_speed, :max_speed, :min_height, :max_height]
|
166
|
-
end
|
167
|
-
|
168
|
-
if recurse then
|
169
|
-
files = Find.find(directory).select { |e| File.extname(e) == ".yaml" }
|
170
|
-
else
|
171
|
-
files = Dir.glob(File.join(directory, "*.yaml"))
|
172
|
-
end
|
173
|
-
query = QueryParser.new.parse(args.join(" "))
|
174
|
-
|
175
|
-
if debug then
|
176
|
-
puts "Searched files: #{files.join(",")}"
|
177
|
-
puts "Searched files count: #{files.size}"
|
178
|
-
puts "Processed query: #{query}"
|
179
|
-
else
|
180
|
-
sidecar_search = Columbus3::SidecarSearch.new
|
181
|
-
sidecar_search.load files
|
182
|
-
match = sidecar_search.search query
|
183
|
-
match.each do |m|
|
184
|
-
string = fields.map { |x| "#{m[x]}"}.join("\t")
|
185
|
-
puts string
|
186
|
-
end
|
187
|
-
end
|
188
|
-
end
|
189
|
-
end
|
190
|
-
|
191
|
-
##############################################################################
|
192
|
-
command :show do
|
193
|
-
banner "#{appname} show [--help] [--filename filename] [--force] [track ...]"
|
194
|
-
description "View tracks"
|
195
|
-
|
196
|
-
on "-f", "--filename=", "Output filename (default is _show.html)"
|
197
|
-
on "--force", "Force rewriting of the js file, even if it already exists"
|
198
|
-
|
199
|
-
run do |opts, args|
|
200
|
-
cmd ="show"
|
201
|
-
|
202
|
-
filename = opts.to_hash[:filename] || "_show.html"
|
203
|
-
force = opts.to_hash[:force]
|
204
|
-
|
205
|
-
args.each do |arg|
|
206
|
-
Columbus3::LeafletRenderer::to_leaflet arg, force
|
207
|
-
end
|
208
|
-
(Columbus3::LeafletRenderer::show filename, args) if args != []
|
209
|
-
end
|
210
|
-
end
|
211
|
-
|
212
|
-
##############################################################################
|
213
|
-
command :graph do
|
214
|
-
banner "#{appname} show [--help] [--filename filename] [--force] track"
|
215
|
-
description "Plot speed and height profile of track"
|
216
|
-
|
217
|
-
on "--force", "Force rewriting of the js file, even if it already exists"
|
218
|
-
|
219
|
-
run do |opts, args|
|
220
|
-
cmd ="graph"
|
221
|
-
|
222
|
-
filename = opts.to_hash[:filename] || "_graph.html"
|
223
|
-
force = opts.to_hash[:force]
|
224
|
-
|
225
|
-
input_filename = args[0]
|
226
|
-
if input_filename
|
227
|
-
Columbus3::FlotRenderer::to_graph_data input_filename, force
|
228
|
-
Columbus3::FlotRenderer::show filename, input_filename
|
229
|
-
else
|
230
|
-
puts "Error: please specify a track file"
|
231
|
-
end
|
232
|
-
end
|
233
|
-
end
|
234
|
-
|
235
|
-
##############################################################################
|
236
|
-
command :export do
|
237
|
-
banner "#{appname} export [--help] [track ...]"
|
238
|
-
description "Export track to GPX"
|
239
|
-
|
240
|
-
run do |opts, args|
|
241
|
-
cmd ="export"
|
242
|
-
puts "Not implemented yet. Use GPSBabel in the meantime."
|
243
|
-
end
|
244
|
-
end
|
245
|
-
end
|
246
|
-
|
247
|
-
if not cmd then
|
248
|
-
puts opts
|
249
|
-
end
|
5
|
+
Columbus3::CommandSemantics.reps Columbus3::CommandSyntax.commands, ARGV
|