The OIDC function from oidc.js is not currently exported neither available from the libnpmpublish package. This mean that to get it working in Lerna/Lerna-Lite (I maintain the latter), we had to copy and reimplement the oidc.js into Lerna/Lerna-Lite to make it work.
There's 2 obvious issues related to this approach:
- duplicate code increasing Lerna/Lerna-Lite project size
- any changes made in
oidc.js needs to be resync manually in external projects like Lerna/Lerna-Lite
libnpmpublish only exports 2 functions (publish and unpublish)
|
module.exports = { |
|
publish: require('./publish.js'), |
|
unpublish: require('./unpublish.js'), |
|
} |
I mention Lerna/Lerna-Lite in here, but I'm sure there's few hundred projects that would benefit from having OIDC available directly in libnpmpublish
The OIDC function from
oidc.jsis not currently exported neither available from thelibnpmpublishpackage. This mean that to get it working in Lerna/Lerna-Lite (I maintain the latter), we had to copy and reimplement theoidc.jsinto Lerna/Lerna-Lite to make it work.There's 2 obvious issues related to this approach:
oidc.jsneeds to be resync manually in external projects like Lerna/Lerna-Liteoidc.tsand Lerna-Liteoidc.tslerna publishwith npm Trusted Publishing fails with E404 for private scoped packages on CircleCI lerna/lerna#4358libnpmpublishonly exports 2 functions (publishandunpublish)cli/workspaces/libnpmpublish/lib/index.js
Lines 1 to 4 in 455aa4a
I mention Lerna/Lerna-Lite in here, but I'm sure there's few hundred projects that would benefit from having OIDC available directly in
libnpmpublish