|
@@ -12,7 +12,8 @@ def collect_config_filenames(config_paths):
|
|
'''
|
|
'''
|
|
Given a sequence of config paths, both filenames and directories, resolve that to just an
|
|
Given a sequence of config paths, both filenames and directories, resolve that to just an
|
|
iterable of files. Accomplish this by listing any given directories looking for contained config
|
|
iterable of files. Accomplish this by listing any given directories looking for contained config
|
|
- files. This is non-recursive, so any directories within the given directories are ignored.
|
|
|
|
|
|
+ files (ending with the ".yaml" extension). This is non-recursive, so any directories within the
|
|
|
|
+ given directories are ignored.
|
|
|
|
|
|
Return paths even if they don't exist on disk, so the user can find out about missing
|
|
Return paths even if they don't exist on disk, so the user can find out about missing
|
|
configuration paths. However, skip a default config path if it's missing, so the user doesn't
|
|
configuration paths. However, skip a default config path if it's missing, so the user doesn't
|
|
@@ -32,5 +33,5 @@ def collect_config_filenames(config_paths):
|
|
|
|
|
|
for filename in os.listdir(path):
|
|
for filename in os.listdir(path):
|
|
full_filename = os.path.join(path, filename)
|
|
full_filename = os.path.join(path, filename)
|
|
- if not os.path.isdir(full_filename):
|
|
|
|
|
|
+ if full_filename.endswith('.yaml') and not os.path.isdir(full_filename):
|
|
yield full_filename
|
|
yield full_filename
|