Blob Blame History Raw
From 4c3cc0ec55edb54de25174e1c534cd7c03281954 Mon Sep 17 00:00:00 2001
From: Elliott Sales de Andrade <quantum.analyst@gmail.com>
Date: Fri, 23 Feb 2018 02:09:01 -0500
Subject: [PATCH 3/7] Add ne_ prefix to NaturalEarth cache files.

This prefix is used in the zip files provided by NaturalEarth, so if you
download anything manually, you need to rename all the files for Cartopy
to find them. This change makes that renaming no longer necessary, at
the expense of a few extra re-downloads.

Signed-off-by: Elliott Sales de Andrade <quantum.analyst@gmail.com>
---
 lib/cartopy/io/shapereader.py | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/lib/cartopy/io/shapereader.py b/lib/cartopy/io/shapereader.py
index fae9367..68471be 100644
--- a/lib/cartopy/io/shapereader.py
+++ b/lib/cartopy/io/shapereader.py
@@ -346,11 +346,11 @@ class NEShpDownloader(Downloader):
             >>> ne_dnldr = NEShpDownloader.default_downloader()
             >>> print(ne_dnldr.target_path_template)
             {config[data_dir]}/shapefiles/natural_earth/{category}/\
-{resolution}_{name}.shp
+ne_{resolution}_{name}.shp
 
         """
         default_spec = ('shapefiles', 'natural_earth', '{category}',
-                        '{resolution}_{name}.shp')
+                        'ne_{resolution}_{name}.shp')
         ne_path_template = os.path.join('{config[data_dir]}', *default_spec)
         pre_path_template = os.path.join('{config[pre_existing_data_dir]}',
                                          *default_spec)
-- 
2.14.3