Skip to content

Commit

Permalink
Change --show-default-configfiles language to clarify priority
Browse files Browse the repository at this point in the history
E.g.:
Default list of existing configuration files (5, most important last):
/home/oldeman/lo/easybuild.d/bla.cfg, /home/oldeman/lo/easybuild.d/foo.cfg, /home/oldeman/hi/easybuild.d/bla.cfg, /home/oldeman/hi/easybuild.d/foo.cfg, /home/oldeman/.config/easybuild/config.cfg
  • Loading branch information
bartoldeman committed Oct 2, 2024
1 parent 9367dce commit 7ebbee1
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 2 deletions.
3 changes: 2 additions & 1 deletion easybuild/tools/options.py
Original file line number Diff line number Diff line change
Expand Up @@ -1337,7 +1337,8 @@ def show_default_configfiles(self):
"* system-level: %s" % os.path.join('${XDG_CONFIG_DIRS:-/etc/xdg}', 'easybuild.d', '*.cfg'),
" -> %s => %s" % (system_cfg_glob_paths, ', '.join(flatten(DEFAULT_SYS_CFGFILES)) or "(no matches)"),
'',
"Default list of existing configuration files (%d): %s" % (found_cfgfile_cnt, found_cfgfile_list),
"Default list of existing configuration files (%d, most important last):" % found_cfgfile_cnt,
found_cfgfile_list,
]
return '\n'.join(lines)

Expand Down
3 changes: 2 additions & 1 deletion test/framework/options.py
Original file line number Diff line number Diff line change
Expand Up @@ -3523,7 +3523,8 @@ def test_show_default_configfiles(self):
expected_tmpl += '\n'.join([
"%s",
'',
"Default list of existing configuration files (%d): %s",
"Default list of existing configuration files (%d, most important last):",
"%s",
])

# put dummy cfgfile in place in $HOME (to predict last line of output which only lists *existing* files)
Expand Down

0 comments on commit 7ebbee1

Please sign in to comment.