1
0
mirror of https://github.com/scrapy/scrapy.git synced 2025-02-24 02:04:22 +00:00

Reversed scrapy.cfg lookup order so that the one in the current project has more precedence. Also added alternative system-wide location for windows.

This commit is contained in:
Pablo Hoffman 2010-10-18 03:18:54 -02:00
parent 98662e53ea
commit deb9c7ef04

View File

@ -55,7 +55,8 @@ def get_config(use_closest=True):
return cfg
def get_sources(use_closest=True):
sources = [os.path.expanduser('~/.scrapy.cfg'), '/etc/scrapy.cfg']
sources = ['/etc/scrapy.cfg', r'c:\scrapy\scrapy.cfg', \
os.path.expanduser('~/.scrapy.cfg')]
if use_closest:
sources.insert(0, closest_scrapy_cfg())
sources.append(closest_scrapy_cfg())
return sources