feat: add support for pnpm config get globalconfig#10090
Merged
Conversation
btea
approved these changes
Oct 20, 2025
Member
btea
left a comment
There was a problem hiding this comment.
I think this feature is quite convenient.
zkochan
requested changes
Oct 21, 2025
Member
zkochan
left a comment
There was a problem hiding this comment.
You are hardcoding the location instead of using the location from '@pnpm/config'. It should be just a regular setting that is present in the config object.
Member
Author
|
@zkochan |
zkochan
reviewed
Oct 22, 2025
| 'bitbucket.com', | ||
| 'bitbucket.org', | ||
| ], | ||
| globalconfig: npmDefaults.globalconfig, |
Member
There was a problem hiding this comment.
the global npm config is still useful for storing auth tokens. Maybe keep it as npm-globalconfig.
Comment on lines
+12
to
+14
| if (key === 'globalconfig') { | ||
| return { output: opts.globalconfig, exitCode: 0 } | ||
| } |
Member
Author
There was a problem hiding this comment.
Good suggestion, I've fixed it.
refactor: move globalconfig to rawConfig
ryo-manba
commented
Oct 27, 2025
| rootProjectManifest?: ProjectManifest | ||
| userConfig: Record<string, string> | ||
|
|
||
| globalconfig: string |
Member
Author
There was a problem hiding this comment.
It's not currently used anywhere. Only needed for config get command.
Can be added back if needed, but what do you think?
zkochan
approved these changes
Nov 8, 2025
zkochan
pushed a commit
that referenced
this pull request
Nov 8, 2025
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Fixes #9977
Added support for
pnpm config get globalconfigto retrieve the global config file path, matching npm's behavior.