Repository 'gdal_ogr2ogr'
hg clone https://toolshed.g2.bx.psu.edu/repos/ecology/gdal_ogr2ogr

Changeset 2:22c54afd1cf3 (2019-06-13)
Previous changeset 1:8c67f7a51e36 (2019-02-27) Next changeset 3:e12db3b4d3a6 (2019-06-20)
Commit message:
planemo upload for repository https://github.com/galaxyecology/tools-ecology/tree/master/tools/gdal commit d2c064afb4680f459012473e4de8653079e32c15
modified:
gdal_macros.xml
ogr2ogr.xml
added:
test-data/ogr2ogr_GML.gml
test-data/ogr2ogr_GML2.gml
test-data/ogr2ogr_KML.kml
test-data/ogr2ogr_geojson.json
test-data/ogr2ogr_test2_geojson.json
test-data/shp_compositefiles/ogr2ogr_shapefile2.dbf
test-data/shp_compositefiles/ogr2ogr_shapefile2.html
test-data/shp_compositefiles/ogr2ogr_shapefile2.prj
test-data/shp_compositefiles/ogr2ogr_shapefile2.shp
test-data/shp_compositefiles/ogr2ogr_shapefile2.shx
test-data/shp_compositefiles/shapefile.dbf
test-data/shp_compositefiles/shapefile.html
test-data/shp_compositefiles/shapefile.sbn
test-data/shp_compositefiles/shapefile.sbx
test-data/shp_compositefiles/shapefile.shp
test-data/shp_compositefiles/shapefile.shx
b
diff -r 8c67f7a51e36 -r 22c54afd1cf3 gdal_macros.xml
--- a/gdal_macros.xml Wed Feb 27 14:15:21 2019 -0500
+++ b/gdal_macros.xml Thu Jun 13 11:29:34 2019 -0400
b
@@ -1,5 +1,5 @@
 <macros>
-    <token name="@VERSION@">2.4.0</token>  
+    <token name="@VERSION@">3.0.0</token>  
     <xml name="gdal_requirements">
         <requirements>
             <requirement type="package" version="@VERSION@">gdal</requirement>
b
diff -r 8c67f7a51e36 -r 22c54afd1cf3 ogr2ogr.xml
--- a/ogr2ogr.xml Wed Feb 27 14:15:21 2019 -0500
+++ b/ogr2ogr.xml Thu Jun 13 11:29:34 2019 -0400
[
b'@@ -2,25 +2,31 @@\n     <description>converts simple features data between file formats</description>\n     <macros>\n         <import>gdal_macros.xml</import>\n-    </macros> \n-    <requirements>\n-        <requirement type="package" version="2.4.0">gdal</requirement>\n-        <requirement type="package" version="3.7.1">geos</requirement>\n-    </requirements>\n+    </macros>\n+    <expand macro="gdal_requirements" />\n     <command detect_errors="exit_code"><![CDATA[\n-        ogr2ogr -f \'$f\'\n+        ogr2ogr\n+            -f \'$f\'\n             #if $f==\'ESRI Shapefile\'\n-                \'output.shp\'\n+                \'shapefile.shp\'\n             #else\n-                \'$output\'\n+                \'output\'\n             #end if\n-            \'$input\'\n+            #if $input.is_of_type("shp")\n+                ${os.path.join( $input.extra_files_path, \'shapefile.shp\' )} \n+            #else    \n+                \'$input\'\n+            #end if\n+            #if $f==\'ESRI Shapefile\'\n+                &&\n+                mkdir ${shapefile.extra_files_path} &&\n+                mv shapefile.* ${shapefile.extra_files_path}\n+            #end if \n     ]]></command>\n     <inputs>\n-        <param type="data" name="input" format="data" label="Gdal supported input file" help="http://www.gdal.org/ogr_formats.html"/>\n-        <param type="select" name="f" label="Conversion format" value=""\n-            help="Select the format to convert your input file. Currently supported : Shapefile, GeoJSON, GML, KML and WFS. The shapefiles outputs shp, shx, dbf and prj will populate a datacollection.">\n-            <option value="ESRI Shapefile">ESRI Shapefile</option> \n+        <param type="data" name="input" format="shp,xml,json,txt" label="Gdal supported input file" help="http://www.gdal.org/ogr_formats.html"/>\n+        <param type="select" name="f" label="Conversion format" value="" help="Select the format to convert your input file. Currently supported : Shapefile, GeoJSON, GML, KML and WFS.">\n+            <option value="ESRI Shapefile">ESRI Shapefile</option>\n             <option value="GeoJSON">GEOJSON</option> \n             <option value="GML">GML</option>\n             <option value="KML">KML</option>\n@@ -28,37 +34,74 @@\n         </param>\n     </inputs>\n     <outputs>\n-        <data name="output" format="xml" label="${on_string}.${f}">\n+        <data name="output" from_work_dir="output" format="xml" label="${on_string}.${f}">\n             <filter>f != \'ESRI Shapefile\'</filter>\n                 <change_format>\n-                    <when input="f" value="GeoJson" format="json"/> \n+                    <when input="f" value="GeoJSON" format="json"/> \n                     <when input="f" value="GML" format="xml"/> \n                     <when input="f" value="KML" format="xml"/> \n                     <when input="f" value="WFS" format="txt"/> \n                 </change_format> \n         </data>\n-        <collection name="shapefile" type="list" label="${on_string}.shapefile">\n+        <data name="shapefile" format="shp" from_work_dir="shapefile" label="${on_string}.shapefile">\n             <filter>f == \'ESRI Shapefile\'</filter>\n-                <data name="shp" format="binary" from_work_dir="*.shp"/>\n-                <data name="shx" format="binary" from_work_dir="*.shx"/>\n-                <data name="dbf" format="binary" from_work_dir="*.dbf"/>\n-                <data name="prj" format="txt" from_work_dir="*.prj"/>\n-       </collection>\n+        </data>\n     </outputs>\n-    \n     <tests>\n-        <test> <!-- ogr2ogr -f KML custom.geo.kml custom.geo.json -->\n-            <param name="input" value="custom.geo.json"/>\n+        <test>\n+            <param name="input" value="shp_compositefiles/shapefile.xml" ftype="shp">\n+                <composite_data value="shp_compositefiles/shapefile.shp"/>\n+                <composite_data value="shp_compositefiles/shapefile.shx"/>\n+                <composite_data value="shp_compositefiles/shapefile.dbf"/>\n+                <composite_data val'..b' 26.8578235206248,48.3682107610945 26.6193367855978,48.2207262233335 26.1974503923669,48.2208812526303 25.9459411964024,47.9871487493742 25.207743361113,47.8910564235275 24.8663171729606,47.7375257431883 24.4020561052504,47.9818777532804 23.7609582862374,47.9855984564055 23.1422363624068,48.0963410508069 22.7105314470405,47.8821939153894 22.6408199398788,48.1502395696874 22.0856083513349,48.4222643092718 22.2808419125336,48.8253921575807 22.5581376482118,49.0857380234671 22.7764188982126,49.0273953314096 22.5184501482116,49.4767735866197 23.4265084164444,50.3085057643574 23.9227571957433,50.4248810898788 24.0299857927489,50.7054066025752 23.5270707536844,51.5784540879302 24.0050777523842,51.6174439560945 24.5531063168395,51.8884610052492 25.327787713327,51.9106560329186 26.3379586117686,51.8322887233479 27.4540661964084,51.5923033717845 28.2416150245366,51.5722270778391 28.6176127458922,51.4277139349348 28.9928353207635,51.6020443792715 29.2549381853479,51.3682343613669 30.1573637224609,51.4161384141015 30.5551172218115,51.3195034857157 30.6194543800148,51.8228060980224 30.927549269339,52.0423534206144 31.7859981625716,52.1016779648855"/>\n-                </assert_contents>\n+            <output file="ogr2ogr_KML.kml" name="output"/> \n+        </test>\n+        <test>\n+            <param name="input" value="shp_compositefiles/shapefile.xml" ftype="shp">\n+                <composite_data value="shp_compositefiles/shapefile.shp"/>\n+                <composite_data value="shp_compositefiles/shapefile.shx"/>\n+                <composite_data value="shp_compositefiles/shapefile.dbf"/>\n+                <composite_data value="shp_compositefiles/shapefile.sbn"/>\n+                <composite_data value="shp_compositefiles/shapefile.sbx"/>\n+            </param>\n+            <param name="f" value="GML"/>\n+            <output file="ogr2ogr_GML.gml" name="output"/> \n+        </test>\n+        <test>\n+            <param name="input" value="shp_compositefiles/shapefile.xml" ftype="shp">\n+                <composite_data value="shp_compositefiles/shapefile.shp"/>\n+                <composite_data value="shp_compositefiles/shapefile.shx"/>\n+                <composite_data value="shp_compositefiles/shapefile.dbf"/>\n+                <composite_data value="shp_compositefiles/shapefile.sbn"/>\n+                <composite_data value="shp_compositefiles/shapefile.sbx"/>\n+            </param>\n+            <param name="f" value="GeoJSON"/>\n+            <output file="ogr2ogr_geojson.json" name="output"/> \n+        </test>   \n+        <test>\n+            <param name="input" value="ogr2ogr_KML.kml" ftype="xml"/>\n+            <param name="f" value="GeoJSON"/>\n+            <output file="ogr2ogr_test2_geojson.json" name="output"/> \n+        </test>   \n+        <test>\n+            <param name="input" value="ogr2ogr_KML.kml" ftype="xml"/>\n+            <param name="f" value="ESRI Shapefile"/>\n+            <output file="shp_compositefiles/ogr2ogr_shapefile2.html" name="shapefile">\n+                <extra_files type="file" name="shapefile.dbf" value="shp_compositefiles/ogr2ogr_shapefile2.dbf" compare="sim_size" delta="50"/>\n+                <extra_files type="file" name="shapefile.prj" value="shp_compositefiles/ogr2ogr_shapefile2.prj"/>\n+                <extra_files type="file" name="shapefile.shp" value="shp_compositefiles/ogr2ogr_shapefile2.shp"/>\n+                <extra_files type="file" name="shapefile.shx" value="shp_compositefiles/ogr2ogr_shapefile2.shx"/>\n             </output>\n         </test>\n+        <test>\n+            <param name="input" value="ogr2ogr_KML.kml" ftype="xml"/>\n+            <param name="f" value="GML"/>\n+            <output file="ogr2ogr_GML2.gml" name="output"/> \n+        </test>\n     </tests>\n-\n     <help><![CDATA[\n ========\n Ogrinfo\n@@ -82,7 +125,7 @@\n \n http://www.gdal.org\n \n-http://www.gdal.org/ogr_utilities.html\n+https://gdal.org/programs/ogr2ogr.html\n \n http://download.osgeo.org/gdal/workshop/foss4ge2015/workshop_gdal.pdf\n     ]]></help>\n'
b
diff -r 8c67f7a51e36 -r 22c54afd1cf3 test-data/ogr2ogr_GML.gml
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/test-data/ogr2ogr_GML.gml Thu Jun 13 11:29:34 2019 -0400
b
b'@@ -0,0 +1,224 @@\n+<?xml version="1.0" encoding="utf-8" ?>\n+<ogr:FeatureCollection\n+     xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"\n+     xsi:schemaLocation="http://ogr.maptools.org/ output.xsd"\n+     xmlns:ogr="http://ogr.maptools.org/"\n+     xmlns:gml="http://www.opengis.net/gml">\n+  <gml:boundedBy>\n+    <gml:Box>\n+      <gml:coord><gml:X>-115.0414962768555</gml:X><gml:Y>15.4399242401123</gml:Y></gml:coord>\n+      <gml:coord><gml:X>-90.65814208984375</gml:X><gml:Y>32.72083282470703</gml:Y></gml:coord>\n+    </gml:Box>\n+  </gml:boundedBy>\n+                                                                                               \n+  <gml:featureMember>\n+    <ogr:shapefile fid="shapefile.0">\n+      <ogr:geometryProperty><gml:LineString><gml:coordinates>-98.7458343505859,21.275203704834 -98.7814025878906,21.1805534362793 -98.9561157226562,21.0749969482422 -98.9625091552734,21.0119438171387 -99.0036163330078,21.0180549621582 -99.0561218261719,20.9449996948242 -99.0222320556641,20.8469429016113 -98.9613952636719,20.8163871765137 -98.8886260986328,20.5819435119629 -98.8352813720703,20.5222206115723 -98.8114013671875,20.3349990844727 -98.7308349609375,20.3258323669434 -98.6977844238281,20.2838859558105</gml:coordinates></gml:LineString></ogr:geometryProperty>\n+      <ogr:NAME>Amajac</ogr:NAME>\n+      <ogr:SYSTEM xsi:nil="true"/>\n+    </ogr:shapefile>\n+  </gml:featureMember>\n+  <gml:featureMember>\n+    <ogr:shapefile fid="shapefile.1">\n+      <ogr:geometryProperty><gml:MultiLineString><gml:lineStringMember><gml:LineString><gml:coordinates>-102.915557861328,19.9305534362793 -102.807342529297,19.8991508483887 -102.891403198242,19.8308296203613 -102.829452514648,19.7719421386719 -102.780288696289,19.4730529785156 -102.745010375977,19.4249992370605 -102.781402587891,19.3777770996094 -102.778625488281,19.2988624572754 -102.812225341797,19.3569412231445 -103.067230224609,19.4474983215332 -103.064727783203,19.556941986084</gml:coordinates></gml:LineString></gml:lineStringMember><gml:lineStringMember><gml:LineString><gml:coordinates>-102.778625488281,19.2988624572754 -102.771392822266,19.1747207641602 -102.637222290039,19.0530548095703 -102.487228393555,19.0136108398438 -102.317779541016,18.8994407653809 -102.131958007812,18.8538856506348 -102.072509765625,18.8486099243164 -102.080291748047,18.892219543457 -102.052230834961,18.913330078125 -102.024726867676,18.8186073303223 -102.001106262207,18.9013862609863 -101.973068237305,18.8866653442383 -101.950286865234,18.9124984741211 -102.000839233398,18.7980537414551 -101.966667175293,18.7616653442383 -101.935012817383,18.7941665649414 -101.933616638184,18.7580528259277 -101.870292663574,18.752498626709 -101.892501831055,18.7308311462402 -101.871116638184,18.692497253418 -101.809448242188,18.7422218322754 -101.852783203125,18.6283302307129 -101.70556640625,18.6705551147461 -101.683059692383,18.6183319091797 -101.651123046875,18.6174964904785 -101.621948242188,18.6763877868652 -101.60334777832,18.594165802002 -101.561683654785,18.5991630554199 -101.559173583984,18.5347213745117 -101.513343811035,18.498607635498 -101.295562744141,18.5336074829102</gml:coordinates></gml:LineString></gml:lineStringMember><gml:lineStringMember><gml:LineString><gml:coordinates>-102.131958007812,18.8538856506348 -102.016403198242,18.7838859558105 -102.000289916992,18.7316665649414 -101.926391601562,18.715274810791 -101.9375,18.6799964904785 -101.876106262207,18.6752777099609 -101.911392211914,18.6499977111816 -101.877227783203,18.6199989318848 -101.918060302734,18.5144424438477 -101.888343811035,18.494441986084 -101.888633728027,18.439998626709 -101.994743347168,18.4752769470215 -101.896118164062,18.4077758789062 -101.870292663574,18.3172187805176 -101.900283813477,18.2613868713379</gml:coordinates></gml:LineString></gml:lineStringMember><gml:lineStringMember><gml:LineString><gml:coordinates>-101.295562744141,18.5336074829102 -101.347229003906,18.4622192382812 -101.436111450195,18.4661102294922 -101.42723'..b'55572509766,16.3080520629883 -91.2894592285156,16.2424964904785 -91.2008361816406,16.2072219848633 -91.1477966308594,16.1442794799805</gml:coordinates></gml:LineString></ogr:geometryProperty>\n+      <ogr:NAME>Tzanconeja</ogr:NAME>\n+      <ogr:SYSTEM>Usumacinta</ogr:SYSTEM>\n+    </ogr:shapefile>\n+  </gml:featureMember>\n+  <gml:featureMember>\n+    <ogr:shapefile fid="shapefile.28">\n+      <ogr:geometryProperty><gml:MultiLineString><gml:lineStringMember><gml:LineString><gml:coordinates>-92.4808349609375,18.656665802002 -92.4102783203125,18.4930534362793 -92.2755584716797,18.406665802002 -92.2769470214844,18.327220916748 -92.2174530029297,18.224967956543 -92.1844482421875,18.1186103820801 -92.1218719482422,18.0884857177734 -92.1408386230469,18.0022201538086 -92.1163940429688,17.9630546569824 -91.9902114868164,17.9119396209717 -91.9898986816406,17.9122200012207 -91.9505615234375,17.8955497741699 -91.945556640625,17.8547191619873 -91.9125137329102,17.8872203826904 -91.8233337402344,17.88916015625 -91.7866668701172,17.8555507659912 -91.7728729248047,17.7736892700195 -91.7936172485352,17.7266693115234 -91.6986236572266,17.7141609191895 -91.6985702514648,17.7140560150146 -91.6202850341797,17.7383308410645 -91.6575012207031,17.7716636657715 -91.6205596923828,17.7813873291016 -91.6161193847656,17.8266639709473 -91.5691680908203,17.8136100769043 -91.5519561767578,17.7469444274902 -91.5136260986328,17.8024978637695 -91.4794464111328,17.7608299255371 -91.4246978759766,17.7649536132812 -91.4525146484375,17.7008323669434 -91.3761138916016,17.7024993896484 -91.4027862548828,17.6424980163574 -91.3577880859375,17.5913887023926 -91.4064025878906,17.5652770996094 -91.5111236572266,17.5833320617676 -91.4305572509766,17.4883308410645 -91.5044555664062,17.4861106872559 -91.5075607299805,17.4697742462158 -91.4961166381836,17.4041595458984 -91.4263916015625,17.3869400024414 -91.3880615234375,17.32666015625 -91.4375,17.2411079406738 -91.352783203125,17.1763877868652 -91.2772369384766,17.1783332824707 -91.1844482421875,17.0355529785156 -91.1183471679688,17.0102767944336 -91.0627899169922,16.902774810791 -90.98583984375,16.8680534362793 -90.9833374023438,16.9030532836914 -90.9552917480469,16.8991661071777 -90.9661254882812,16.8719444274902 -90.9211120605469,16.829719543457 -90.8033447265625,16.8049964904785 -90.7142791748047,16.7264595031738 -90.6581420898438,16.6442737579346</gml:coordinates></gml:LineString></gml:lineStringMember><gml:lineStringMember><gml:LineString><gml:coordinates>-92.1218719482422,18.0884857177734 -92.0816802978516,18.1216659545898 -92.0847320556641,18.2377777099609 -91.901123046875,18.3549995422363 -91.8577880859375,18.4291648864746</gml:coordinates></gml:LineString></gml:lineStringMember></gml:MultiLineString></ogr:geometryProperty>\n+      <ogr:NAME>Usumacinta</ogr:NAME>\n+      <ogr:SYSTEM>Usumacinta</ogr:SYSTEM>\n+    </ogr:shapefile>\n+  </gml:featureMember>\n+  <gml:featureMember>\n+    <ogr:shapefile fid="shapefile.29">\n+      <ogr:geometryProperty><gml:LineString><gml:coordinates>-109.619186401367,28.9040546417236 -109.636672973633,28.7522201538086 -109.552505493164,28.6002769470215 -109.550567626953,28.5308303833008 -109.521392822266,28.5341644287109 -109.520004272461,28.4683303833008 -109.682510375977,28.1736106872559 -109.798065185547,28.1430549621582 -109.832229614258,28.1683311462402 -109.878890991211,28.1324996948242 -109.789726257324,27.9897193908691 -109.802230834961,27.942497253418 -109.870826721191,27.9058303833008 -109.917793273926,27.958610534668 -109.894508361816,27.8341808319092 -109.922225952148,27.6377754211426 -110.113067626953,27.5424995422363 -110.131393432617,27.571662902832 -110.29833984375,27.594165802002 -110.369445800781,27.6419410705566 -110.463348388672,27.5924987792969 -110.599166870117,27.6577758789062</gml:coordinates></gml:LineString></ogr:geometryProperty>\n+      <ogr:NAME>Yaqui</ogr:NAME>\n+      <ogr:SYSTEM>Yaqui</ogr:SYSTEM>\n+    </ogr:shapefile>\n+  </gml:featureMember>\n+</ogr:FeatureCollection>\n'
b
diff -r 8c67f7a51e36 -r 22c54afd1cf3 test-data/ogr2ogr_GML2.gml
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/test-data/ogr2ogr_GML2.gml Thu Jun 13 11:29:34 2019 -0400
b
b'@@ -0,0 +1,224 @@\n+<?xml version="1.0" encoding="utf-8" ?>\n+<ogr:FeatureCollection\n+     xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"\n+     xsi:schemaLocation="http://ogr.maptools.org/ output.xsd"\n+     xmlns:ogr="http://ogr.maptools.org/"\n+     xmlns:gml="http://www.opengis.net/gml">\n+  <gml:boundedBy>\n+    <gml:Box>\n+      <gml:coord><gml:X>15.4399242401123</gml:X><gml:Y>-115.041496276855</gml:Y></gml:coord>\n+      <gml:coord><gml:X>32.720832824707</gml:X><gml:Y>-90.65814208984381</gml:Y></gml:coord>\n+    </gml:Box>\n+  </gml:boundedBy>\n+                                                                                                  \n+  <gml:featureMember>\n+    <ogr:shapefile fid="shapefile.0">\n+      <ogr:geometryProperty><gml:LineString srsName="EPSG:4326"><gml:coordinates>21.275203704834,-98.7458343505859 21.1805534362793,-98.7814025878906 21.0749969482422,-98.9561157226562 21.0119438171387,-98.9625091552734 21.0180549621582,-99.0036163330078 20.9449996948242,-99.0561218261719 20.8469429016113,-99.0222320556641 20.8163871765137,-98.9613952636719 20.5819435119629,-98.8886260986328 20.5222206115723,-98.8352813720703 20.3349990844727,-98.8114013671875 20.3258323669434,-98.7308349609375 20.2838859558105,-98.6977844238281</gml:coordinates></gml:LineString></ogr:geometryProperty>\n+      <ogr:Name>Amajac</ogr:Name>\n+      <ogr:Description></ogr:Description>\n+    </ogr:shapefile>\n+  </gml:featureMember>\n+  <gml:featureMember>\n+    <ogr:shapefile fid="shapefile.1">\n+      <ogr:geometryProperty><gml:MultiLineString srsName="EPSG:4326"><gml:lineStringMember><gml:LineString><gml:coordinates>19.9305534362793,-102.915557861328 19.8991508483887,-102.807342529297 19.8308296203613,-102.891403198242 19.7719421386719,-102.829452514648 19.4730529785156,-102.780288696289 19.4249992370605,-102.745010375977 19.3777770996094,-102.781402587891 19.2988624572754,-102.778625488281 19.3569412231445,-102.812225341797 19.4474983215332,-103.067230224609 19.556941986084,-103.064727783203</gml:coordinates></gml:LineString></gml:lineStringMember><gml:lineStringMember><gml:LineString><gml:coordinates>19.2988624572754,-102.778625488281 19.1747207641602,-102.771392822266 19.0530548095703,-102.637222290039 19.0136108398438,-102.487228393555 18.8994407653809,-102.317779541016 18.8538856506348,-102.131958007812 18.8486099243164,-102.072509765625 18.892219543457,-102.080291748047 18.913330078125,-102.052230834961 18.8186073303223,-102.024726867676 18.9013862609863,-102.001106262207 18.8866653442383,-101.973068237305 18.9124984741211,-101.950286865234 18.7980537414551,-102.000839233398 18.7616653442383,-101.966667175293 18.7941665649414,-101.935012817383 18.7580528259277,-101.933616638184 18.752498626709,-101.870292663574 18.7308311462402,-101.892501831055 18.692497253418,-101.871116638184 18.7422218322754,-101.809448242188 18.6283302307129,-101.852783203125 18.6705551147461,-101.70556640625 18.6183319091797,-101.683059692383 18.6174964904785,-101.651123046875 18.6763877868652,-101.621948242188 18.594165802002,-101.60334777832 18.5991630554199,-101.561683654785 18.5347213745117,-101.559173583984 18.498607635498,-101.513343811035 18.5336074829102,-101.295562744141</gml:coordinates></gml:LineString></gml:lineStringMember><gml:lineStringMember><gml:LineString><gml:coordinates>18.8538856506348,-102.131958007812 18.7838859558105,-102.016403198242 18.7316665649414,-102.000289916992 18.715274810791,-101.926391601562 18.6799964904785,-101.9375 18.6752777099609,-101.876106262207 18.6499977111816,-101.911392211914 18.6199989318848,-101.877227783203 18.5144424438477,-101.918060302734 18.494441986084,-101.888343811035 18.439998626709,-101.888633728027 18.4752769470215,-101.994743347168 18.4077758789062,-101.896118164062 18.3172187805176,-101.870292663574 18.2613868713379,-101.900283813477</gml:coordinates></gml:LineString></gml:lineStringMember><gml:lineStringMember><gml:LineString><gml:coordinates>18.5336074829102,-101.295562744141 18.4622192382812,-101.34722900390'..b',-91.2894592285156 16.2072219848633,-91.2008361816406 16.1442794799805,-91.1477966308594</gml:coordinates></gml:LineString></ogr:geometryProperty>\n+      <ogr:Name>Tzanconeja</ogr:Name>\n+      <ogr:Description></ogr:Description>\n+    </ogr:shapefile>\n+  </gml:featureMember>\n+  <gml:featureMember>\n+    <ogr:shapefile fid="shapefile.28">\n+      <ogr:geometryProperty><gml:MultiLineString srsName="EPSG:4326"><gml:lineStringMember><gml:LineString><gml:coordinates>18.656665802002,-92.4808349609375 18.4930534362793,-92.4102783203125 18.406665802002,-92.2755584716797 18.327220916748,-92.2769470214844 18.224967956543,-92.2174530029297 18.1186103820801,-92.1844482421875 18.0884857177734,-92.1218719482422 18.0022201538086,-92.1408386230469 17.9630546569824,-92.1163940429688 17.9119396209717,-91.9902114868164 17.9122200012207,-91.9898986816406 17.8955497741699,-91.9505615234375 17.8547191619873,-91.945556640625 17.8872203826904,-91.9125137329102 17.88916015625,-91.8233337402344 17.8555507659912,-91.7866668701172 17.7736892700195,-91.7728729248047 17.7266693115234,-91.7936172485352 17.7141609191895,-91.6986236572266 17.7140560150146,-91.6985702514648 17.7383308410645,-91.6202850341797 17.7716636657715,-91.6575012207031 17.7813873291016,-91.6205596923828 17.8266639709473,-91.6161193847656 17.8136100769043,-91.5691680908203 17.7469444274902,-91.5519561767578 17.8024978637695,-91.5136260986328 17.7608299255371,-91.4794464111328 17.7649536132812,-91.4246978759766 17.7008323669434,-91.4525146484375 17.7024993896484,-91.3761138916016 17.6424980163574,-91.4027862548828 17.5913887023926,-91.3577880859375 17.5652770996094,-91.4064025878906 17.5833320617676,-91.5111236572266 17.4883308410645,-91.4305572509766 17.4861106872559,-91.5044555664062 17.4697742462158,-91.5075607299805 17.4041595458984,-91.4961166381836 17.3869400024414,-91.4263916015625 17.32666015625,-91.3880615234375 17.2411079406738,-91.4375 17.1763877868652,-91.352783203125 17.1783332824707,-91.2772369384766 17.0355529785156,-91.1844482421875 17.0102767944336,-91.1183471679688 16.902774810791,-91.0627899169922 16.8680534362793,-90.98583984375 16.9030532836914,-90.9833374023438 16.8991661071777,-90.9552917480469 16.8719444274902,-90.9661254882812 16.829719543457,-90.9211120605469 16.8049964904785,-90.8033447265625 16.7264595031738,-90.7142791748047 16.6442737579346,-90.6581420898438</gml:coordinates></gml:LineString></gml:lineStringMember><gml:lineStringMember><gml:LineString><gml:coordinates>18.0884857177734,-92.1218719482422 18.1216659545898,-92.0816802978516 18.2377777099609,-92.0847320556641 18.3549995422363,-91.901123046875 18.4291648864746,-91.8577880859375</gml:coordinates></gml:LineString></gml:lineStringMember></gml:MultiLineString></ogr:geometryProperty>\n+      <ogr:Name>Usumacinta</ogr:Name>\n+      <ogr:Description></ogr:Description>\n+    </ogr:shapefile>\n+  </gml:featureMember>\n+  <gml:featureMember>\n+    <ogr:shapefile fid="shapefile.29">\n+      <ogr:geometryProperty><gml:LineString srsName="EPSG:4326"><gml:coordinates>28.9040546417236,-109.619186401367 28.7522201538086,-109.636672973633 28.6002769470215,-109.552505493164 28.5308303833008,-109.550567626953 28.5341644287109,-109.521392822266 28.4683303833008,-109.520004272461 28.1736106872559,-109.682510375977 28.1430549621582,-109.798065185547 28.1683311462402,-109.832229614258 28.1324996948242,-109.878890991211 27.9897193908691,-109.789726257324 27.942497253418,-109.802230834961 27.9058303833008,-109.870826721191 27.958610534668,-109.917793273926 27.8341808319092,-109.894508361816 27.6377754211426,-109.922225952148 27.5424995422363,-110.113067626953 27.571662902832,-110.131393432617 27.594165802002,-110.29833984375 27.6419410705566,-110.369445800781 27.5924987792969,-110.463348388672 27.6577758789062,-110.599166870117</gml:coordinates></gml:LineString></ogr:geometryProperty>\n+      <ogr:Name>Yaqui</ogr:Name>\n+      <ogr:Description></ogr:Description>\n+    </ogr:shapefile>\n+  </gml:featureMember>\n+</ogr:FeatureCollection>\n'
b
diff -r 8c67f7a51e36 -r 22c54afd1cf3 test-data/ogr2ogr_KML.kml
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/test-data/ogr2ogr_KML.kml Thu Jun 13 11:29:34 2019 -0400
b
b'@@ -0,0 +1,213 @@\n+<?xml version="1.0" encoding="utf-8" ?>\n+<kml xmlns="http://www.opengis.net/kml/2.2">\n+<Document id="root_doc">\n+<Schema name="shapefile" id="shapefile">\n+\t<SimpleField name="SYSTEM" type="string"></SimpleField>\n+</Schema>\n+<Folder><name>shapefile</name>\n+  <Placemark>\n+\t<name>Amajac</name>\n+\t<Style><LineStyle><color>ff0000ff</color></LineStyle><PolyStyle><fill>0</fill></PolyStyle></Style>\n+      <LineString><coordinates>-98.7458343505859,21.275203704834 -98.7814025878906,21.1805534362793 -98.9561157226562,21.0749969482422 -98.9625091552734,21.0119438171387 -99.0036163330078,21.0180549621582 -99.0561218261719,20.9449996948242 -99.0222320556641,20.8469429016113 -98.9613952636719,20.8163871765137 -98.8886260986328,20.5819435119629 -98.8352813720703,20.5222206115723 -98.8114013671875,20.3349990844727 -98.7308349609375,20.3258323669434 -98.6977844238281,20.2838859558105</coordinates></LineString>\n+  </Placemark>\n+  <Placemark>\n+\t<name>Balsas</name>\n+\t<Style><LineStyle><color>ff0000ff</color></LineStyle><PolyStyle><fill>0</fill></PolyStyle></Style>\n+\t<ExtendedData><SchemaData schemaUrl="#shapefile">\n+\t\t<SimpleData name="SYSTEM">Balsas</SimpleData>\n+\t</SchemaData></ExtendedData>\n+      <MultiGeometry><LineString><coordinates>-102.915557861328,19.9305534362793 -102.807342529297,19.8991508483887 -102.891403198242,19.8308296203613 -102.829452514648,19.7719421386719 -102.780288696289,19.4730529785156 -102.745010375977,19.4249992370605 -102.781402587891,19.3777770996094 -102.778625488281,19.2988624572754 -102.812225341797,19.3569412231445 -103.067230224609,19.4474983215332 -103.064727783203,19.556941986084</coordinates></LineString><LineString><coordinates>-102.778625488281,19.2988624572754 -102.771392822266,19.1747207641602 -102.637222290039,19.0530548095703 -102.487228393555,19.0136108398438 -102.317779541016,18.8994407653809 -102.131958007812,18.8538856506348 -102.072509765625,18.8486099243164 -102.080291748047,18.892219543457 -102.052230834961,18.913330078125 -102.024726867676,18.8186073303223 -102.001106262207,18.9013862609863 -101.973068237305,18.8866653442383 -101.950286865234,18.9124984741211 -102.000839233398,18.7980537414551 -101.966667175293,18.7616653442383 -101.935012817383,18.7941665649414 -101.933616638184,18.7580528259277 -101.870292663574,18.752498626709 -101.892501831055,18.7308311462402 -101.871116638184,18.692497253418 -101.809448242188,18.7422218322754 -101.852783203125,18.6283302307129 -101.70556640625,18.6705551147461 -101.683059692383,18.6183319091797 -101.651123046875,18.6174964904785 -101.621948242188,18.6763877868652 -101.60334777832,18.594165802002 -101.561683654785,18.5991630554199 -101.559173583984,18.5347213745117 -101.513343811035,18.498607635498 -101.295562744141,18.5336074829102</coordinates></LineString><LineString><coordinates>-102.131958007812,18.8538856506348 -102.016403198242,18.7838859558105 -102.000289916992,18.7316665649414 -101.926391601562,18.715274810791 -101.9375,18.6799964904785 -101.876106262207,18.6752777099609 -101.911392211914,18.6499977111816 -101.877227783203,18.6199989318848 -101.918060302734,18.5144424438477 -101.888343811035,18.494441986084 -101.888633728027,18.439998626709 -101.994743347168,18.4752769470215 -101.896118164062,18.4077758789062 -101.870292663574,18.3172187805176 -101.900283813477,18.2613868713379</coordinates></LineString><LineString><coordinates>-101.295562744141,18.5336074829102 -101.347229003906,18.4622192382812 -101.436111450195,18.4661102294922 -101.427230834961,18.4272193908691 -101.587783813477,18.5158309936523 -101.634170532227,18.5922203063965 -101.725852966309,18.5322189331055 -101.769180297852,18.5769424438477 -101.847778320312,18.5477752685547 -101.870010375977,18.4916648864746 -101.851119995117,18.2958297729492 -101.787231445312,18.2894439697266 -101.836402893066,18.2391662597656 -101.900283813477,18.2613868713379</coordinates></LineString><LineString><coordinates>-101.295562744141,18.5336074829102 -101.087509155273,18.5011100769043 -1'..b'025878906,16.5238876342773 -91.4183349609375,16.4847221374512 -91.4000091552734,16.4247207641602 -91.3388977050781,16.3847198486328 -91.3408355712891,16.3219413757324 -91.3055572509766,16.3080520629883 -91.2894592285156,16.2424964904785 -91.2008361816406,16.2072219848633 -91.1477966308594,16.1442794799805</coordinates></LineString>\n+  </Placemark>\n+  <Placemark>\n+\t<name>Usumacinta</name>\n+\t<Style><LineStyle><color>ff0000ff</color></LineStyle><PolyStyle><fill>0</fill></PolyStyle></Style>\n+\t<ExtendedData><SchemaData schemaUrl="#shapefile">\n+\t\t<SimpleData name="SYSTEM">Usumacinta</SimpleData>\n+\t</SchemaData></ExtendedData>\n+      <MultiGeometry><LineString><coordinates>-92.4808349609375,18.656665802002 -92.4102783203125,18.4930534362793 -92.2755584716797,18.406665802002 -92.2769470214844,18.327220916748 -92.2174530029297,18.224967956543 -92.1844482421875,18.1186103820801 -92.1218719482422,18.0884857177734 -92.1408386230469,18.0022201538086 -92.1163940429688,17.9630546569824 -91.9902114868164,17.9119396209717 -91.9898986816406,17.9122200012207 -91.9505615234375,17.8955497741699 -91.945556640625,17.8547191619873 -91.9125137329102,17.8872203826904 -91.8233337402344,17.88916015625 -91.7866668701172,17.8555507659912 -91.7728729248047,17.7736892700195 -91.7936172485352,17.7266693115234 -91.6986236572266,17.7141609191895 -91.6985702514648,17.7140560150146 -91.6202850341797,17.7383308410645 -91.6575012207031,17.7716636657715 -91.6205596923828,17.7813873291016 -91.6161193847656,17.8266639709473 -91.5691680908203,17.8136100769043 -91.5519561767578,17.7469444274902 -91.5136260986328,17.8024978637695 -91.4794464111328,17.7608299255371 -91.4246978759766,17.7649536132812 -91.4525146484375,17.7008323669434 -91.3761138916016,17.7024993896484 -91.4027862548828,17.6424980163574 -91.3577880859375,17.5913887023926 -91.4064025878906,17.5652770996094 -91.5111236572266,17.5833320617676 -91.4305572509766,17.4883308410645 -91.5044555664062,17.4861106872559 -91.5075607299805,17.4697742462158 -91.4961166381836,17.4041595458984 -91.4263916015625,17.3869400024414 -91.3880615234375,17.32666015625 -91.4375,17.2411079406738 -91.352783203125,17.1763877868652 -91.2772369384766,17.1783332824707 -91.1844482421875,17.0355529785156 -91.1183471679688,17.0102767944336 -91.0627899169922,16.902774810791 -90.98583984375,16.8680534362793 -90.9833374023438,16.9030532836914 -90.9552917480469,16.8991661071777 -90.9661254882812,16.8719444274902 -90.9211120605469,16.829719543457 -90.8033447265625,16.8049964904785 -90.7142791748047,16.7264595031738 -90.6581420898438,16.6442737579346</coordinates></LineString><LineString><coordinates>-92.1218719482422,18.0884857177734 -92.0816802978516,18.1216659545898 -92.0847320556641,18.2377777099609 -91.901123046875,18.3549995422363 -91.8577880859375,18.4291648864746</coordinates></LineString></MultiGeometry>\n+  </Placemark>\n+  <Placemark>\n+\t<name>Yaqui</name>\n+\t<Style><LineStyle><color>ff0000ff</color></LineStyle><PolyStyle><fill>0</fill></PolyStyle></Style>\n+\t<ExtendedData><SchemaData schemaUrl="#shapefile">\n+\t\t<SimpleData name="SYSTEM">Yaqui</SimpleData>\n+\t</SchemaData></ExtendedData>\n+      <LineString><coordinates>-109.619186401367,28.9040546417236 -109.636672973633,28.7522201538086 -109.552505493164,28.6002769470215 -109.550567626953,28.5308303833008 -109.521392822266,28.5341644287109 -109.520004272461,28.4683303833008 -109.682510375977,28.1736106872559 -109.798065185547,28.1430549621582 -109.832229614258,28.1683311462402 -109.878890991211,28.1324996948242 -109.789726257324,27.9897193908691 -109.802230834961,27.942497253418 -109.870826721191,27.9058303833008 -109.917793273926,27.958610534668 -109.894508361816,27.8341808319092 -109.922225952148,27.6377754211426 -110.113067626953,27.5424995422363 -110.131393432617,27.571662902832 -110.29833984375,27.594165802002 -110.369445800781,27.6419410705566 -110.463348388672,27.5924987792969 -110.599166870117,27.6577758789062</coordinates></LineString>\n+  </Placemark>\n+</Folder>\n+</Document></kml>\n'
b
diff -r 8c67f7a51e36 -r 22c54afd1cf3 test-data/ogr2ogr_geojson.json
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/test-data/ogr2ogr_geojson.json Thu Jun 13 11:29:34 2019 -0400
[
b'@@ -0,0 +1,36 @@\n+{\n+"type": "FeatureCollection",\n+"name": "shapefile",\n+"features": [\n+{ "type": "Feature", "properties": { "NAME": "Amajac", "SYSTEM": null }, "geometry": { "type": "LineString", "coordinates": [ [ -98.745834350585938, 21.275203704833984 ], [ -98.781402587890625, 21.180553436279297 ], [ -98.95611572265625, 21.074996948242188 ], [ -98.962509155273438, 21.011943817138672 ], [ -99.003616333007812, 21.018054962158203 ], [ -99.056121826171875, 20.944999694824219 ], [ -99.022232055664062, 20.846942901611328 ], [ -98.961395263671875, 20.816387176513672 ], [ -98.888626098632812, 20.581943511962891 ], [ -98.835281372070312, 20.522220611572266 ], [ -98.8114013671875, 20.334999084472656 ], [ -98.7308349609375, 20.325832366943359 ], [ -98.697784423828125, 20.283885955810547 ] ] } },\n+{ "type": "Feature", "properties": { "NAME": "Balsas", "SYSTEM": "Balsas" }, "geometry": { "type": "MultiLineString", "coordinates": [ [ [ -102.915557861328125, 19.930553436279297 ], [ -102.807342529296875, 19.899150848388672 ], [ -102.891403198242188, 19.830829620361328 ], [ -102.829452514648438, 19.771942138671875 ], [ -102.780288696289062, 19.473052978515625 ], [ -102.745010375976562, 19.424999237060547 ], [ -102.781402587890625, 19.377777099609375 ], [ -102.77862548828125, 19.298862457275391 ], [ -102.812225341796875, 19.356941223144531 ], [ -103.067230224609375, 19.447498321533203 ], [ -103.064727783203125, 19.556941986083984 ] ], [ [ -102.77862548828125, 19.298862457275391 ], [ -102.771392822265625, 19.174720764160156 ], [ -102.637222290039062, 19.053054809570312 ], [ -102.487228393554688, 19.01361083984375 ], [ -102.317779541015625, 18.899440765380859 ], [ -102.1319580078125, 18.853885650634766 ], [ -102.072509765625, 18.848609924316406 ], [ -102.080291748046875, 18.892219543457031 ], [ -102.052230834960938, 18.913330078125 ], [ -102.024726867675781, 18.818607330322266 ], [ -102.001106262207031, 18.901386260986328 ], [ -101.973068237304688, 18.886665344238281 ], [ -101.950286865234375, 18.912498474121094 ], [ -102.000839233398438, 18.798053741455078 ], [ -101.966667175292969, 18.761665344238281 ], [ -101.935012817382812, 18.794166564941406 ], [ -101.933616638183594, 18.758052825927734 ], [ -101.870292663574219, 18.752498626708984 ], [ -101.892501831054688, 18.730831146240234 ], [ -101.871116638183594, 18.692497253417969 ], [ -101.8094482421875, 18.742221832275391 ], [ -101.852783203125, 18.628330230712891 ], [ -101.70556640625, 18.670555114746094 ], [ -101.683059692382812, 18.618331909179688 ], [ -101.651123046875, 18.617496490478516 ], [ -101.6219482421875, 18.676387786865234 ], [ -101.603347778320312, 18.594165802001953 ], [ -101.561683654785156, 18.599163055419922 ], [ -101.559173583984375, 18.534721374511719 ], [ -101.513343811035156, 18.498607635498047 ], [ -101.295562744140625, 18.533607482910156 ] ], [ [ -102.1319580078125, 18.853885650634766 ], [ -102.016403198242188, 18.783885955810547 ], [ -102.000289916992188, 18.731666564941406 ], [ -101.9263916015625, 18.715274810791016 ], [ -101.9375, 18.679996490478516 ], [ -101.876106262207031, 18.675277709960938 ], [ -101.911392211914062, 18.649997711181641 ], [ -101.877227783203125, 18.619998931884766 ], [ -101.918060302734375, 18.514442443847656 ], [ -101.888343811035156, 18.494441986083984 ], [ -101.888633728027344, 18.439998626708984 ], [ -101.994743347167969, 18.475276947021484 ], [ -101.8961181640625, 18.40777587890625 ], [ -101.870292663574219, 18.317218780517578 ], [ -101.900283813476562, 18.261386871337891 ] ], [ [ -101.295562744140625, 18.533607482910156 ], [ -101.34722900390625, 18.46221923828125 ], [ -101.436111450195312, 18.466110229492188 ], [ -101.427230834960938, 18.427219390869141 ], [ -101.587783813476562, 18.515830993652344 ], [ -101.634170532226562, 18.592220306396484 ], [ -101.725852966308594, 18.532218933105469 ], [ -101.769180297851562, 18.576942443847656 ], [ -101.8477783203125, 18.547775268554688 ], [ -101.870010375976562, 18.491664886474609 ], [ -101.8511199'..b'863281 ], [ -91.147796630859375, 16.144279479980469 ] ] } },\n+{ "type": "Feature", "properties": { "NAME": "Usumacinta", "SYSTEM": "Usumacinta" }, "geometry": { "type": "MultiLineString", "coordinates": [ [ [ -92.4808349609375, 18.656665802001953 ], [ -92.4102783203125, 18.493053436279297 ], [ -92.275558471679688, 18.406665802001953 ], [ -92.276947021484375, 18.327220916748047 ], [ -92.217453002929688, 18.224967956542969 ], [ -92.1844482421875, 18.118610382080078 ], [ -92.121871948242188, 18.088485717773438 ], [ -92.140838623046875, 18.002220153808594 ], [ -92.11639404296875, 17.963054656982422 ], [ -91.990211486816406, 17.91193962097168 ], [ -91.989898681640625, 17.912220001220703 ], [ -91.9505615234375, 17.895549774169922 ], [ -91.945556640625, 17.854719161987305 ], [ -91.912513732910156, 17.88722038269043 ], [ -91.823333740234375, 17.88916015625 ], [ -91.786666870117188, 17.855550765991211 ], [ -91.772872924804688, 17.773689270019531 ], [ -91.793617248535156, 17.726669311523438 ], [ -91.698623657226562, 17.714160919189453 ], [ -91.698570251464844, 17.714056015014648 ], [ -91.620285034179688, 17.738330841064453 ], [ -91.657501220703125, 17.771663665771484 ], [ -91.620559692382812, 17.781387329101562 ], [ -91.616119384765625, 17.826663970947266 ], [ -91.569168090820312, 17.813610076904297 ], [ -91.551956176757812, 17.746944427490234 ], [ -91.513626098632812, 17.802497863769531 ], [ -91.479446411132812, 17.760829925537109 ], [ -91.424697875976562, 17.76495361328125 ], [ -91.4525146484375, 17.700832366943359 ], [ -91.376113891601562, 17.702499389648438 ], [ -91.402786254882812, 17.642498016357422 ], [ -91.3577880859375, 17.591388702392578 ], [ -91.406402587890625, 17.565277099609375 ], [ -91.511123657226562, 17.583332061767578 ], [ -91.430557250976562, 17.488330841064453 ], [ -91.50445556640625, 17.486110687255859 ], [ -91.507560729980469, 17.46977424621582 ], [ -91.496116638183594, 17.404159545898438 ], [ -91.4263916015625, 17.386940002441406 ], [ -91.3880615234375, 17.32666015625 ], [ -91.4375, 17.241107940673828 ], [ -91.352783203125, 17.176387786865234 ], [ -91.277236938476562, 17.178333282470703 ], [ -91.1844482421875, 17.035552978515625 ], [ -91.11834716796875, 17.010276794433594 ], [ -91.062789916992188, 16.902774810791016 ], [ -90.98583984375, 16.868053436279297 ], [ -90.98333740234375, 16.903053283691406 ], [ -90.955291748046875, 16.899166107177734 ], [ -90.96612548828125, 16.871944427490234 ], [ -90.921112060546875, 16.829719543457031 ], [ -90.8033447265625, 16.804996490478516 ], [ -90.714279174804688, 16.726459503173828 ], [ -90.65814208984375, 16.64427375793457 ] ], [ [ -92.121871948242188, 18.088485717773438 ], [ -92.081680297851562, 18.121665954589844 ], [ -92.084732055664062, 18.237777709960938 ], [ -91.901123046875, 18.354999542236328 ], [ -91.8577880859375, 18.429164886474609 ] ] ] } },\n+{ "type": "Feature", "properties": { "NAME": "Yaqui", "SYSTEM": "Yaqui" }, "geometry": { "type": "LineString", "coordinates": [ [ -109.619186401367188, 28.904054641723633 ], [ -109.636672973632812, 28.752220153808594 ], [ -109.552505493164062, 28.600276947021484 ], [ -109.550567626953125, 28.530830383300781 ], [ -109.521392822265625, 28.534164428710938 ], [ -109.520004272460938, 28.468330383300781 ], [ -109.682510375976562, 28.173610687255859 ], [ -109.798065185546875, 28.143054962158203 ], [ -109.832229614257812, 28.168331146240234 ], [ -109.878890991210938, 28.132499694824219 ], [ -109.789726257324219, 27.989719390869141 ], [ -109.802230834960938, 27.942497253417969 ], [ -109.870826721191406, 27.905830383300781 ], [ -109.917793273925781, 27.958610534667969 ], [ -109.894508361816406, 27.83418083190918 ], [ -109.922225952148438, 27.637775421142578 ], [ -110.113067626953125, 27.542499542236328 ], [ -110.131393432617188, 27.571662902832031 ], [ -110.29833984375, 27.594165802001953 ], [ -110.36944580078125, 27.641941070556641 ], [ -110.463348388671875, 27.592498779296875 ], [ -110.599166870117188, 27.65777587890625 ] ] } }\n+]\n+}\n'
b
diff -r 8c67f7a51e36 -r 22c54afd1cf3 test-data/ogr2ogr_test2_geojson.json
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/test-data/ogr2ogr_test2_geojson.json Thu Jun 13 11:29:34 2019 -0400
[
b'@@ -0,0 +1,37 @@\n+{\n+"type": "FeatureCollection",\n+"name": "shapefile",\n+"crs": { "type": "name", "properties": { "name": "urn:ogc:def:crs:OGC:1.3:CRS84" } },\n+"features": [\n+{ "type": "Feature", "properties": { "Name": "Amajac", "Description": "" }, "geometry": { "type": "LineString", "coordinates": [ [ -98.745834350585895, 21.275203704833999 ], [ -98.781402587890597, 21.1805534362793 ], [ -98.956115722656193, 21.074996948242202 ], [ -98.962509155273395, 21.0119438171387 ], [ -99.003616333007798, 21.0180549621582 ], [ -99.056121826171903, 20.944999694824201 ], [ -99.022232055664105, 20.8469429016113 ], [ -98.961395263671903, 20.8163871765137 ], [ -98.888626098632798, 20.581943511962901 ], [ -98.835281372070298, 20.522220611572301 ], [ -98.8114013671875, 20.334999084472699 ], [ -98.7308349609375, 20.325832366943398 ], [ -98.697784423828097, 20.283885955810501 ] ] } },\n+{ "type": "Feature", "properties": { "Name": "Balsas", "Description": "" }, "geometry": { "type": "MultiLineString", "coordinates": [ [ [ -102.915557861327997, 19.9305534362793 ], [ -102.807342529297003, 19.8991508483887 ], [ -102.891403198242003, 19.8308296203613 ], [ -102.829452514647997, 19.7719421386719 ], [ -102.780288696289006, 19.4730529785156 ], [ -102.745010375977003, 19.424999237060501 ], [ -102.781402587890994, 19.3777770996094 ], [ -102.778625488280994, 19.298862457275401 ], [ -102.812225341797003, 19.356941223144499 ], [ -103.067230224609006, 19.4474983215332 ], [ -103.064727783202997, 19.556941986083999 ] ], [ [ -102.778625488280994, 19.298862457275401 ], [ -102.771392822265994, 19.174720764160199 ], [ -102.637222290039006, 19.053054809570298 ], [ -102.487228393555, 19.0136108398438 ], [ -102.317779541015994, 18.899440765380898 ], [ -102.131958007812003, 18.853885650634801 ], [ -102.072509765625, 18.848609924316399 ], [ -102.080291748047003, 18.892219543456999 ], [ -102.052230834960994, 18.913330078125 ], [ -102.024726867675994, 18.818607330322301 ], [ -102.001106262207003, 18.9013862609863 ], [ -101.973068237305, 18.886665344238299 ], [ -101.950286865234006, 18.912498474121101 ], [ -102.000839233397997, 18.798053741455099 ], [ -101.966667175292997, 18.761665344238299 ], [ -101.935012817382997, 18.794166564941399 ], [ -101.933616638184006, 18.758052825927699 ], [ -101.870292663574006, 18.752498626708999 ], [ -101.892501831055, 18.730831146240199 ], [ -101.871116638184006, 18.692497253418001 ], [ -101.809448242187997, 18.742221832275401 ], [ -101.852783203125, 18.628330230712901 ], [ -101.70556640625, 18.670555114746101 ], [ -101.683059692382997, 18.618331909179702 ], [ -101.651123046875, 18.617496490478501 ], [ -101.621948242187997, 18.676387786865199 ], [ -101.60334777832, 18.594165802001999 ], [ -101.561683654785, 18.599163055419901 ], [ -101.559173583984006, 18.534721374511701 ], [ -101.513343811035, 18.498607635498001 ], [ -101.295562744140994, 18.533607482910199 ] ], [ [ -102.131958007812003, 18.853885650634801 ], [ -102.016403198242003, 18.783885955810501 ], [ -102.000289916992003, 18.731666564941399 ], [ -101.926391601562003, 18.715274810791001 ], [ -101.9375, 18.679996490478501 ], [ -101.876106262207003, 18.675277709960898 ], [ -101.911392211914006, 18.649997711181602 ], [ -101.877227783202997, 18.619998931884801 ], [ -101.918060302734006, 18.514442443847699 ], [ -101.888343811035, 18.494441986083999 ], [ -101.888633728027003, 18.439998626708999 ], [ -101.994743347167997, 18.475276947021499 ], [ -101.896118164062003, 18.4077758789062 ], [ -101.870292663574006, 18.317218780517599 ], [ -101.900283813477003, 18.261386871337901 ] ], [ [ -101.295562744140994, 18.533607482910199 ], [ -101.347229003905994, 18.4622192382812 ], [ -101.436111450195, 18.466110229492202 ], [ -101.427230834960994, 18.427219390869102 ], [ -101.587783813477003, 18.515830993652301 ], [ -101.634170532227003, 18.592220306396499 ], [ -101.725852966309006, 18.532218933105501 ], [ -101.769180297852003, 18.576942443847699 ], [ -101.847778320312003, 18.547775268554702 ], [ -101.'..b'181640597, 16.207221984863299 ], [ -91.147796630859403, 16.144279479980501 ] ] } },\n+{ "type": "Feature", "properties": { "Name": "Usumacinta", "Description": "" }, "geometry": { "type": "MultiLineString", "coordinates": [ [ [ -92.4808349609375, 18.656665802001999 ], [ -92.4102783203125, 18.4930534362793 ], [ -92.275558471679702, 18.406665802001999 ], [ -92.276947021484403, 18.327220916748001 ], [ -92.217453002929702, 18.224967956543001 ], [ -92.1844482421875, 18.118610382080099 ], [ -92.121871948242202, 18.088485717773398 ], [ -92.140838623046903, 18.002220153808601 ], [ -92.116394042968807, 17.963054656982401 ], [ -91.990211486816406, 17.911939620971701 ], [ -91.989898681640597, 17.9122200012207 ], [ -91.9505615234375, 17.895549774169901 ], [ -91.945556640625, 17.854719161987301 ], [ -91.912513732910199, 17.887220382690401 ], [ -91.823333740234403, 17.88916015625 ], [ -91.786666870117202, 17.8555507659912 ], [ -91.772872924804702, 17.773689270019499 ], [ -91.793617248535199, 17.726669311523398 ], [ -91.698623657226605, 17.714160919189499 ], [ -91.698570251464801, 17.714056015014599 ], [ -91.620285034179702, 17.738330841064499 ], [ -91.657501220703097, 17.771663665771499 ], [ -91.620559692382798, 17.781387329101602 ], [ -91.616119384765597, 17.826663970947301 ], [ -91.569168090820298, 17.8136100769043 ], [ -91.551956176757798, 17.746944427490199 ], [ -91.513626098632798, 17.802497863769499 ], [ -91.479446411132798, 17.760829925537099 ], [ -91.424697875976605, 17.7649536132812 ], [ -91.4525146484375, 17.700832366943398 ], [ -91.376113891601605, 17.702499389648398 ], [ -91.402786254882798, 17.642498016357401 ], [ -91.3577880859375, 17.591388702392599 ], [ -91.406402587890597, 17.5652770996094 ], [ -91.511123657226605, 17.583332061767599 ], [ -91.430557250976605, 17.488330841064499 ], [ -91.504455566406193, 17.486110687255898 ], [ -91.507560729980497, 17.469774246215799 ], [ -91.496116638183594, 17.404159545898398 ], [ -91.4263916015625, 17.386940002441399 ], [ -91.3880615234375, 17.32666015625 ], [ -91.4375, 17.2411079406738 ], [ -91.352783203125, 17.176387786865199 ], [ -91.277236938476605, 17.1783332824707 ], [ -91.1844482421875, 17.0355529785156 ], [ -91.118347167968807, 17.010276794433601 ], [ -91.062789916992202, 16.902774810791001 ], [ -90.98583984375, 16.8680534362793 ], [ -90.983337402343807, 16.903053283691399 ], [ -90.955291748046903, 16.899166107177699 ], [ -90.966125488281193, 16.871944427490199 ], [ -90.921112060546903, 16.829719543456999 ], [ -90.8033447265625, 16.804996490478501 ], [ -90.714279174804702, 16.7264595031738 ], [ -90.658142089843807, 16.644273757934599 ] ], [ [ -92.121871948242202, 18.088485717773398 ], [ -92.081680297851605, 18.121665954589801 ], [ -92.084732055664105, 18.237777709960898 ], [ -91.901123046875, 18.3549995422363 ], [ -91.8577880859375, 18.429164886474599 ] ] ] } },\n+{ "type": "Feature", "properties": { "Name": "Yaqui", "Description": "" }, "geometry": { "type": "LineString", "coordinates": [ [ -109.619186401367003, 28.904054641723601 ], [ -109.636672973632997, 28.752220153808601 ], [ -109.552505493164006, 28.600276947021499 ], [ -109.550567626952997, 28.530830383300799 ], [ -109.521392822265994, 28.534164428710898 ], [ -109.520004272460994, 28.468330383300799 ], [ -109.682510375977003, 28.173610687255898 ], [ -109.798065185547003, 28.1430549621582 ], [ -109.832229614257997, 28.168331146240199 ], [ -109.878890991210994, 28.132499694824201 ], [ -109.789726257324006, 27.989719390869102 ], [ -109.802230834960994, 27.942497253418001 ], [ -109.870826721190994, 27.905830383300799 ], [ -109.917793273925994, 27.958610534668001 ], [ -109.894508361815994, 27.834180831909201 ], [ -109.922225952147997, 27.637775421142599 ], [ -110.113067626952997, 27.5424995422363 ], [ -110.131393432617003, 27.571662902831999 ], [ -110.29833984375, 27.594165802001999 ], [ -110.369445800780994, 27.641941070556602 ], [ -110.463348388672003, 27.5924987792969 ], [ -110.599166870117003, 27.6577758789062 ] ] } }\n+]\n+}\n'
b
diff -r 8c67f7a51e36 -r 22c54afd1cf3 test-data/shp_compositefiles/ogr2ogr_shapefile2.dbf
b
Binary file test-data/shp_compositefiles/ogr2ogr_shapefile2.dbf has changed
b
diff -r 8c67f7a51e36 -r 22c54afd1cf3 test-data/shp_compositefiles/ogr2ogr_shapefile2.html
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/test-data/shp_compositefiles/ogr2ogr_shapefile2.html Thu Jun 13 11:29:34 2019 -0400
b
@@ -0,0 +1,17 @@
+<html><head><title>Shapefile Galaxy Composite Dataset</title></head><p/>
+<div>This composite dataset is composed of the following files:<p/><ul>
+<li><a href="shapefile.shp" type="application/binary">shapefile.shp (Geometry File (shp))</a></li>
+<li><a href="shapefile.shx" type="application/binary">shapefile.shx (Geometry index File (shx))</a></li>
+<li><a href="shapefile.dbf" type="application/binary">shapefile.dbf (Columnar attributes for each shape (dbf))</a></li>
+<li><a href="shapefile.prj" type="application/binary">shapefile.prj (Projection description (prj))</a> (optional)</li>
+<li><a href="shapefile.sbn" type="application/binary">shapefile.sbn (Spatial index of the features (sbn))</a> (optional)</li>
+<li><a href="shapefile.sbx" type="application/binary">shapefile.sbx (Spatial index of the features (sbx))</a> (optional)</li>
+<li><a href="shapefile.fbn" type="application/binary">shapefile.fbn (Read only spatial index of the features (fbn))</a> (optional)</li>
+<li><a href="shapefile.fbx" type="application/binary">shapefile.fbx (Read only spatial index of the features (fbx))</a> (optional)</li>
+<li><a href="shapefile.ain" type="application/binary">shapefile.ain (Attribute index of the active fields in a table (ain))</a> (optional)</li>
+<li><a href="shapefile.aih" type="application/binary">shapefile.aih (Attribute index of the active fields in a table (aih))</a> (optional)</li>
+<li><a href="shapefile.atx" type="application/binary">shapefile.atx (Attribute index for the dbf file (atx))</a> (optional)</li>
+<li><a href="shapefile.ixs" type="application/binary">shapefile.ixs (Geocoding index (ixs))</a> (optional)</li>
+<li><a href="shapefile.mxs" type="application/binary">shapefile.mxs (Geocoding index in ODB format (mxs))</a> (optional)</li>
+<li><a href="shapefile.shp.xml" type="application/binary">shapefile.shp.xml (Geospatial metadata in XML format (xml))</a> (optional)</li>
+</ul></div></html>
b
diff -r 8c67f7a51e36 -r 22c54afd1cf3 test-data/shp_compositefiles/ogr2ogr_shapefile2.prj
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/test-data/shp_compositefiles/ogr2ogr_shapefile2.prj Thu Jun 13 11:29:34 2019 -0400
[
@@ -0,0 +1,1 @@
+GEOGCS["GCS_WGS_1984",DATUM["D_WGS_1984",SPHEROID["WGS_1984",6378137.0,298.257223563]],PRIMEM["Greenwich",0.0],UNIT["Degree",0.0174532925199433]]
\ No newline at end of file
b
diff -r 8c67f7a51e36 -r 22c54afd1cf3 test-data/shp_compositefiles/ogr2ogr_shapefile2.shp
b
Binary file test-data/shp_compositefiles/ogr2ogr_shapefile2.shp has changed
b
diff -r 8c67f7a51e36 -r 22c54afd1cf3 test-data/shp_compositefiles/ogr2ogr_shapefile2.shx
b
Binary file test-data/shp_compositefiles/ogr2ogr_shapefile2.shx has changed
b
diff -r 8c67f7a51e36 -r 22c54afd1cf3 test-data/shp_compositefiles/shapefile.dbf
b
Binary file test-data/shp_compositefiles/shapefile.dbf has changed
b
diff -r 8c67f7a51e36 -r 22c54afd1cf3 test-data/shp_compositefiles/shapefile.html
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/test-data/shp_compositefiles/shapefile.html Thu Jun 13 11:29:34 2019 -0400
b
@@ -0,0 +1,17 @@
+<html><head><title>Shapefile Galaxy Composite Dataset</title></head><p/>
+<div>This composite dataset is composed of the following files:<p/><ul>
+<li><a href="shapefile.shp" type="application/binary">shapefile.shp (Geometry File (shp))</a></li>
+<li><a href="shapefile.shx" type="application/binary">shapefile.shx (Geometry index File (shx))</a></li>
+<li><a href="shapefile.dbf" type="application/binary">shapefile.dbf (Columnar attributes for each shape (dbf))</a></li>
+<li><a href="shapefile.prj" type="application/binary">shapefile.prj (Projection description (prj))</a> (optional)</li>
+<li><a href="shapefile.sbn" type="application/binary">shapefile.sbn (Spatial index of the features (sbn))</a> (optional)</li>
+<li><a href="shapefile.sbx" type="application/binary">shapefile.sbx (Spatial index of the features (sbx))</a> (optional)</li>
+<li><a href="shapefile.fbn" type="application/binary">shapefile.fbn (Read only spatial index of the features (fbn))</a> (optional)</li>
+<li><a href="shapefile.fbx" type="application/binary">shapefile.fbx (Read only spatial index of the features (fbx))</a> (optional)</li>
+<li><a href="shapefile.ain" type="application/binary">shapefile.ain (Attribute index of the active fields in a table (ain))</a> (optional)</li>
+<li><a href="shapefile.aih" type="application/binary">shapefile.aih (Attribute index of the active fields in a table (aih))</a> (optional)</li>
+<li><a href="shapefile.atx" type="application/binary">shapefile.atx (Attribute index for the dbf file (atx))</a> (optional)</li>
+<li><a href="shapefile.ixs" type="application/binary">shapefile.ixs (Geocoding index (ixs))</a> (optional)</li>
+<li><a href="shapefile.mxs" type="application/binary">shapefile.mxs (Geocoding index in ODB format (mxs))</a> (optional)</li>
+<li><a href="shapefile.shp.xml" type="application/binary">shapefile.shp.xml (Geospatial metadata in XML format (xml))</a> (optional)</li>
+</ul></div></html>
b
diff -r 8c67f7a51e36 -r 22c54afd1cf3 test-data/shp_compositefiles/shapefile.sbn
b
Binary file test-data/shp_compositefiles/shapefile.sbn has changed
b
diff -r 8c67f7a51e36 -r 22c54afd1cf3 test-data/shp_compositefiles/shapefile.sbx
b
Binary file test-data/shp_compositefiles/shapefile.sbx has changed
b
diff -r 8c67f7a51e36 -r 22c54afd1cf3 test-data/shp_compositefiles/shapefile.shp
b
Binary file test-data/shp_compositefiles/shapefile.shp has changed
b
diff -r 8c67f7a51e36 -r 22c54afd1cf3 test-data/shp_compositefiles/shapefile.shx
b
Binary file test-data/shp_compositefiles/shapefile.shx has changed