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
Support extracting compiled binary from local offline mirror #459
Conversation
lib/install.js
Outdated
place_binary(from,to,opts,after_place); | ||
var fileName = from.startsWith('file://') && from.replace(/^file:\/\//, ''); | ||
if (fileName) { | ||
extract_from_local(fileName, to, callback); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
You're passing callback
here, but I think you meant after_place
. Right now, if the extract_from_local
function fails, (and it can, with file not found for instance), it'll not potentially fallback to building from source, which is the role of after_place
.
@nicolasnoble, thanks for the quick review. I made the changes, updated the commit, and force-pushed, but not sure this is the preferred way to contribute here. Would you prefer I make a commit on top of it to fix this one line instead? |
I'm fine either way :-) |
I'll publish this as 0.13.1 shortly. |
Than's great, thanks so much @nicolasnoble! When do you expect it to be published? Looking to pull this into our repo soon so we can fix this longstanding issue :) Thanks for the quick turnaround!! |
Hey @nicolasnoble, when are you planning to publish the new release? We are waiting on this to unblock issues we are facing with our environment :) |
pinging this @nicolasnoble |
Support extracting compiled binary from local offline mirror
See #458
This makes it possible to pass in a path to a local file using the
{module_name}_binary_host_mirror
command line argument (or env variable if using Yarn). Thefile://
prefix is used to determine that this is pointing to a local offline mirror, instead of a URL.