diff --git a/plugins/npm/__tests__/npm.test.ts b/plugins/npm/__tests__/npm.test.ts index 7430484a2..c8e58de52 100644 --- a/plugins/npm/__tests__/npm.test.ts +++ b/plugins/npm/__tests__/npm.test.ts @@ -681,6 +681,7 @@ describe("publish", () => { "--yes", "from-package", "--exact", + "--no-verify-access" ]); }); @@ -703,6 +704,7 @@ describe("publish", () => { "--yes", "from-package", false, + "--no-verify-access" ]); }); @@ -728,6 +730,7 @@ describe("publish", () => { false, "--legacy-auth", "abcd", + "--no-verify-access" ]); }); @@ -752,6 +755,7 @@ describe("publish", () => { false, "--contents", "dist/publish-folder", + "--no-verify-access" ]); }); diff --git a/plugins/npm/src/index.ts b/plugins/npm/src/index.ts index 63f29567b..af23b08a7 100644 --- a/plugins/npm/src/index.ts +++ b/plugins/npm/src/index.ts @@ -1447,6 +1447,7 @@ export default class NPMPlugin implements IPlugin { ...(await getRegistryArgs()), ...getPublishFolderArgs(this.publishFolder, { isMonorepo: true }), ...getLegacyAuthArgs(this.legacyAuth, { isMonorepo: true }), + "--no-verify-access", // permit automation tokens https://github.com/lerna/lerna/issues/2788 ]); } else { const { private: isPrivate } = await loadPackageJson();