Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: support publish --provenance #6436

Merged
merged 2 commits into from Apr 24, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
6 changes: 6 additions & 0 deletions .changeset/modern-planes-cough.md
@@ -0,0 +1,6 @@
---
"@pnpm/plugin-commands-publishing": minor
"pnpm": minor
---

`pnpm publish` supports the `--provenance` CLI option [#6435](https://github.com/pnpm/pnpm/issues/6435).
17 changes: 7 additions & 10 deletions packages/mount-modules/test/__fixtures__/simple/pnpm-lock.yaml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

1 change: 1 addition & 0 deletions releasing/plugin-commands-publishing/src/publish.ts
Expand Up @@ -22,6 +22,7 @@ export function rcOptionsTypes () {
'access',
'git-checks',
'ignore-scripts',
'provenance',
'npm-path',
'otp',
'publish-branch',
Expand Down
13 changes: 13 additions & 0 deletions releasing/plugin-commands-publishing/test/publish.ts
Expand Up @@ -726,3 +726,16 @@ test('publish: exit with non-zero code when publish tgz', async () => {
])
expect(result?.exitCode).not.toBe(0)
})

test('publish: provenance', async () => {
prepare({
name: 'test-publish-package.json',
version: '0.0.2',
})

await publish.handler({
...DEFAULT_OPTS,
argv: { original: ['publish', '--provenance'] },
dir: process.cwd(),
}, [])
})