Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Improves the output of "yarn config" (#5713)
**What's the problem this PR addresses?** It's a little difficult to ask people to check specific values of their configuration at the moment. They need to run `yarn config get <name>` to see the value, or `yarn config --why | grep <name>`, but that isn't very visible. **How did you fix it?** It's a bit of an experiment to try to change the output from: <img width="1383" alt="image" src="https://github.com/yarnpkg/berry/assets/1037931/9bf659e3-52e8-44ff-bb0a-e626c4235a68"> To the new tree display: <img width="952" alt="image" src="https://github.com/yarnpkg/berry/assets/1037931/3d8ef4d7-751d-4d1e-abc9-8757c3ae564a"> To offset the lack of compaction, the command now also accepts a list of setting names on the command line, so you can write the following: ``` yarn config nodeLinker ``` Or even multiple parameters: ``` yarn config supportedArchitectures enableGlobalCache ``` <img width="831" alt="image" src="https://github.com/yarnpkg/berry/assets/1037931/eec9490c-6e14-4c1b-a3b6-dfb858890298"> **Checklist** <!--- Don't worry if you miss something, chores are automatically tested. --> <!--- This checklist exists to help you remember doing the chores when you submit a PR. --> <!--- Put an `x` in all the boxes that apply. --> - [x] I have read the [Contributing Guide](https://yarnpkg.com/advanced/contributing). <!-- See https://yarnpkg.com/advanced/contributing#preparing-your-pr-to-be-released for more details. --> <!-- Check with `yarn version check` and fix with `yarn version check -i` --> - [x] I have set the packages that need to be released for my changes to be effective. <!-- The "Testing chores" workflow validates that your PR follows our guidelines. --> <!-- If it doesn't pass, click on it to see details as to what your PR might be missing. --> - [x] I will check that all automated PR checks pass before the PR gets reviewed.
- Loading branch information