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

npm-publish does not support the "prepack" lifecycle script #182

Open
brianblakely opened this issue Jul 16, 2021 · 0 comments
Open

npm-publish does not support the "prepack" lifecycle script #182

brianblakely opened this issue Jul 16, 2021 · 0 comments
Labels
bug Something isn't working

Comments

@brianblakely
Copy link

Describe the bug
https://github.com/jfrog/jfrog-cli-core/blob/master/artifactory/utils/npm/pack.go#L16

The above line expects the output of npm pack to be only the filename of the tarball. However, when using the prepack lifecycle script, the output includes information about that script. Because packageFileName is incorrect, the CLI cannot deploy the tarball and throws an error akin to the following:

open /usr/src/app/foo/> @foo/[email protected] prepack /usr/src/app/foo
  > npm run build-lib
  > @foo/[email protected] build-lib /usr/src/app/foo
  > tsc --p tsconfig.lib.json
  foo-bar-9.90.0-alpha.5.tgz: no such file or directory

To Reproduce
Attempt to deploy an npm package via the JFrog CLI npm-publish command with any prepack lifecycle script in package.json.

Expected behavior
The prepack script should run, preparing files for deployment, and the tarball that npm created should be published.

Versions

  • JFrog CLI version (if applicable): 1.50.2
@brianblakely brianblakely added the bug Something isn't working label Jul 16, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

1 participant