[gimp-web/testing] pelicanconf: no .htaccess in STATIC_PATHS for any environment.



commit 71864f68c3efc48efa788262f9cfb3078f70f590
Author: Jehan <jehan girinstud io>
Date:   Sat Feb 1 16:11:04 2020 +0100

    pelicanconf: no .htaccess in STATIC_PATHS for any environment.
    
    As far as we can see, this makes no difference as we don't see any
    .htaccess file in the repository anyway. The difference existed in the
    old duplicated pelicanconf*.py, so I kept the same code logics when
    merging, for safety, but this was probably just a bug because of
    duplication of code (hence the real need for the merge). So let's rip it
    out! (as Pat says)

 pelicanconf_common.py | 12 +++---------
 1 file changed, 3 insertions(+), 9 deletions(-)
---
diff --git a/pelicanconf_common.py b/pelicanconf_common.py
index d0381788..b7b4fd71 100644
--- a/pelicanconf_common.py
+++ b/pelicanconf_common.py
@@ -24,16 +24,12 @@ AUTHOR_FEED_RSS = None
 DELETE_OUTPUT_DIRECTORY = False
 RELATIVE_URLS = False
 
-# This will copy over these folders w/o modification
-STATIC_PATHS = ['images', 'js', 'pages', 'tutorials', 'about', 'books', 'develop', 'docs', 'donating', 
'downloads', 'features', 'bugs', 'links', 'man', 'release-notes', 'screenshots', 'source', 'unix', 
'robots.txt', 'COPYING', 'GNUGPLv2', 'GNUGPLv3', 'news', 'contribute.json', '.htaccess', 'gimp_versions.json']
-
 def customize_environment(environment):
     global SITEURL, SITEMAP_SITEURL
     global LOAD_CONTENT_CACHE, CHECK_MODIFIED_METHOD, CACHE_CONTENT
     global FEED_DOMAIN, FEED_ATOM, FEED_RSS
     global DELETE_OUTPUT_DIRECTORY
     global RELATIVE_URLS
-    global STATIC_PATHS
 
     valid_environments = [ 'local', 'testing', 'production' ]
     if environment not in valid_environments:
@@ -66,15 +62,13 @@ def customize_environment(environment):
     # When publishing, set to False
     RELATIVE_URLS = True if environment == 'local' else False
 
-    if environment != 'production':
-        # Not sure why, but production pelicanconf didn't have .htaccess
-        # in the list. Was it an error?
-        STATIC_PATHS += ['.htaccess']
-
 #######################################
 ## Values common to all environments ##
 #######################################
 
+# This will copy over these folders w/o modification
+STATIC_PATHS = ['images', 'js', 'pages', 'tutorials', 'about', 'books', 'develop', 'docs', 'donating', 
'downloads', 'features', 'bugs', 'links', 'man', 'release-notes', 'screenshots', 'source', 'unix', 
'robots.txt', 'COPYING', 'GNUGPLv2', 'GNUGPLv3', 'news', 'contribute.json', 'gimp_versions.json']
+
 #Plugins
 PLUGIN_PATHS = ["plugins"]
 #PLUGINS = ["page_hierarchy_gimp"]


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]