npm i / npm ci for multiple target archs #648
|
I can't find any documentation on the --target-arch and --target-platform arguments to Is that possible in a single command? if not several? if several, how would I know if files had been overwritten? How could I confirm the state of my node_modules is correct? Does |
Replies: 3 comments 4 replies
|
Just bumping this up - I don't think I'm asking for any code here, just some clarification of documentation / some advice please? @MylesBorins sorry to tag - is there anyone you know who might be able to answer this question please? |
|
are you building a package that you want to distribute binaries for, or just trying to package up your project that is building third party packages? |
|
@samskiter I think the article you referenced actually gets a number of things wrong. Checking in your Example: Although not recommended, many package maintainers also use With this in mind, & for the best results, it makes sense to run That said, if you run As per @nlf's note, |
@samskiter I think the article you referenced actually gets a number of things wrong. Checking in your
node_modulesfolder will not ensure that your project/application will work across different architectures/platforms. We do a best effort to install dependencies but there are a number of conditions which may meannpm installdoes not make the samenode_modulesacross different platforms/architectures.Example:
npmwill actually fail to install optional dependencies if their supportedos(process.platform) orcpu(ie.process.arch) definitions mismatch the current platforms/environment (this is why they're considered optional & we do a best effort in all cases).engines(ref. https://doc…