mirror of
https://github.com/pnpm/pnpm.git
synced 2026-05-19 06:07:59 -04: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
|
directory?: string
|
||||||
linkDirectory?: boolean
|
linkDirectory?: boolean
|
||||||
executableFiles?: string[]
|
executableFiles?: string[]
|
||||||
|
registry?: string
|
||||||
}
|
}
|
||||||
|
|
||||||
type Version = string
|
type Version = string
|
||||||
|
|||||||
@@ -105,6 +105,7 @@ export async function recursivePublish (
|
|||||||
const publishResults = await Promise.all(chunk.map(async (pkgDir) => {
|
const publishResults = await Promise.all(chunk.map(async (pkgDir) => {
|
||||||
if (!publishedPkgDirs.has(pkgDir)) return null
|
if (!publishedPkgDirs.has(pkgDir)) return null
|
||||||
const pkg = opts.selectedProjectsGraph[pkgDir].package
|
const pkg = opts.selectedProjectsGraph[pkgDir].package
|
||||||
|
const registry = pkg.manifest.publishConfig?.registry ?? pickRegistryForPackage(opts.registries, pkg.manifest.name!)
|
||||||
const publishResult = await publish({
|
const publishResult = await publish({
|
||||||
...opts,
|
...opts,
|
||||||
dir: pkg.dir,
|
dir: pkg.dir,
|
||||||
@@ -114,7 +115,7 @@ export async function recursivePublish (
|
|||||||
'--tag',
|
'--tag',
|
||||||
tag,
|
tag,
|
||||||
'--registry',
|
'--registry',
|
||||||
pickRegistryForPackage(opts.registries, pkg.manifest.name!),
|
registry,
|
||||||
...appendedArgs,
|
...appendedArgs,
|
||||||
],
|
],
|
||||||
},
|
},
|
||||||
|
|||||||
Reference in New Issue
Block a user