You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I've been working my way through the code in the main branch, and I'm starting to have a few thoughts about the existing `package` and proposed `package-spec` inputs:
I'm not sure overriding the working directory is important or useful, compared to exposing the package-spec arg (or a workspace option, in the future), so we can probably drop the idea of working-directory for now
If the package-spec is a pre-packed tarball, then we still need something to point us to package.json so we can read the package name / current version.
Or maybe we extract package.json from the archive?
If package-spec is a directory, we should use the package.json in the directory, I think
What do you think of these points? To brainstorm something:
Keep the package arg
If package unspecified, default to regular npm behavior: use the cwd as the current package
If package is a package.json file, use the directory of that file as the package_spec argument to npm
If package is a directory, look for a package.json in that directory and use the directory as the package_spec arg to npm
What do you think of these points? To brainstorm something:...
That looks like the right logic to me. And yes, we should extract the package.json file from the tar file, not require another argument. I don't think we need to extract it to the file system though, we should just be able to read it into memory.
The text was updated successfully, but these errors were encountered:
package-spec
arg (or aworkspace
option, in the future), so we can probably drop the idea ofworking-directory
for nowpackage-spec
is a pre-packed tarball, then we still need something to point us to package.json so we can read the package name / current version.package-spec
is a directory, we should use the package.json in the directory, I thinkWhat do you think of these points? To brainstorm something:
package
argpackage
unspecified, default to regular npm behavior: use the cwd as the current packagepackage
is a package.json file, use the directory of that file as the package_spec argument to npmpackage
is a directory, look for apackage.json
in that directory and use the directory as the package_spec arg to npmpackage
is an archive, I'm not surepackage-manifest
input?Originally posted by @mcous in #69 (comment)
That looks like the right logic to me. And yes, we should extract the
package.json
file from the tar file, not require another argument. I don't think we need to extract it to the file system though, we should just be able to read it into memory.The text was updated successfully, but these errors were encountered: