Skip to content

Conversation

@thorsten-klein
Copy link
Contributor

@thorsten-klein thorsten-klein commented Oct 21, 2025

Extracted from #867

Why?

It is helpful for users to see which configuration files are currently being used by west, and in which order they are applied.
This makes it easier to debug configuration issues and understand where specific settings originate from.

Proposal

Introduce a new command-line option --list-paths, which prints all configuration files that are currently considered and exist.
The files are listed in the order they are loaded, as later files override values from earlier ones.

This option can be combined with --local, --global, or --system to list only the path for a specific configuration level.

@codecov
Copy link

codecov bot commented Oct 21, 2025

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 84.41%. Comparing base (a53dbf4) to head (1682248).
⚠️ Report is 2 commits behind head on main.

Additional details and impacted files

Impacted file tree graph

@@            Coverage Diff             @@
##             main     #870      +/-   ##
==========================================
+ Coverage   84.34%   84.41%   +0.07%     
==========================================
  Files          11       11              
  Lines        3366     3382      +16     
==========================================
+ Hits         2839     2855      +16     
  Misses        527      527              
Files with missing lines Coverage Δ
src/west/app/config.py 94.05% <100.00%> (+0.44%) ⬆️
src/west/configuration.py 82.16% <100.00%> (+0.52%) ⬆️

@pdgendt
Copy link
Collaborator

pdgendt commented Oct 21, 2025

The command does not appear to work correctly in my Zephyr workspace (my local config file is not printed):

$ cat .west/config
[manifest]
path = zephyr
file = west.yml
group-filter = +optional

[zephyr]
base = zephyr

$ west config --list-paths
/home/pdgendt/.westconfig

$ west config --list-paths --local

$ west config manifest.path
zephyr

Copy link
Collaborator

@pdgendt pdgendt left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good, small nit

The command prints a list of all configuration files currently
considered and existing. They are listed in the order as they are
loaded.
@pdgendt pdgendt merged commit 50cbc34 into zephyrproject-rtos:main Oct 21, 2025
26 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants