mirror of
https://github.com/pnpm/pnpm.git
synced 2025-12-23 23:29:17 -05:00
7
.changeset/angry-goats-divide.md
Normal file
7
.changeset/angry-goats-divide.md
Normal file
@@ -0,0 +1,7 @@
|
||||
---
|
||||
"@pnpm/plugin-commands-publishing": minor
|
||||
"@pnpm/types": minor
|
||||
"pnpm": patch
|
||||
---
|
||||
|
||||
Support `publishConfig.registry` in `package.json` for publishing [#6775](https://github.com/pnpm/pnpm/issues/6775).
|
||||
@@ -56,6 +56,7 @@ export interface PublishConfig extends Record<string, unknown> {
|
||||
directory?: string
|
||||
linkDirectory?: boolean
|
||||
executableFiles?: string[]
|
||||
registry?: string
|
||||
}
|
||||
|
||||
type Version = string
|
||||
|
||||
@@ -105,6 +105,7 @@ export async function recursivePublish (
|
||||
const publishResults = await Promise.all(chunk.map(async (pkgDir) => {
|
||||
if (!publishedPkgDirs.has(pkgDir)) return null
|
||||
const pkg = opts.selectedProjectsGraph[pkgDir].package
|
||||
const registry = pkg.manifest.publishConfig?.registry ?? pickRegistryForPackage(opts.registries, pkg.manifest.name!)
|
||||
const publishResult = await publish({
|
||||
...opts,
|
||||
dir: pkg.dir,
|
||||
@@ -114,7 +115,7 @@ export async function recursivePublish (
|
||||
'--tag',
|
||||
tag,
|
||||
'--registry',
|
||||
pickRegistryForPackage(opts.registries, pkg.manifest.name!),
|
||||
registry,
|
||||
...appendedArgs,
|
||||
],
|
||||
},
|
||||
|
||||
Reference in New Issue
Block a user