Giter Site home page Giter Site logo

Comments (8)

mathiask88 avatar mathiask88 commented on June 2, 2024 1

@ralphtheninja I meant this behavior.

from prebuild-install.

mathiask88 avatar mathiask88 commented on June 2, 2024

No, this is currently not possible. The standalone check was implemented as a little help for the module developers, so they don't have to specify --build-from-source every time they want to build their modules.

@ralphtheninja I see two options here:

  1. remove the standalone path (major)
  2. add a new argument for this case like --force-download that skips the standalone check (minor).

I am tending to 1 because prebuild-install was made to download the binary. And it should only exit if a user don't want to or a download is not possible. And for developer there are still two aliases for --build-from-source --compile and -c wich should be documented :)

from prebuild-install.

ralphtheninja avatar ralphtheninja commented on June 2, 2024

I need to convince prebuild-install to not download and not error, or convince node-gyp to not build if it gets run.

I was a bit confused by this. If I understand correctly, you want prebuild-install to download and if that fails it should fail?

How about adding prebuild-install --test instead, you could then have a pretest script that's being run when testing (or add another script and execute it explicitly in e.g. .travis.yml)

@mathiask88 What do you mean with "the standalone path"?

from prebuild-install.

reconbot avatar reconbot commented on June 2, 2024

I think the --test flag would need to process.exit(0) to prevent the binary from being built from node-gyp with the recommended setup.

Unless --test would be used for testing to see if it could download the package and not actually installing the binary?

I'd prefer to keep this in the install processes so I can verify that not only it downloaded but the download works.

eg

npm install --prebuild-test
node ./ # Would fail if binary isn't present 

Funny enough this works on linux, false takes any argument and fails

node-gyp rebuild --make=false

but I don't know how to pass it through npm install

from prebuild-install.

mathiask88 avatar mathiask88 commented on June 2, 2024

Oh, ok I misread. I thought you want to download the binary in your dev environment, ignore my last answer then :)

from prebuild-install.

ralphtheninja avatar ralphtheninja commented on June 2, 2024

Oh, ok I misread. I thought you want to download the binary in your dev environment, ignore my last answer then :)

This is my current understanding as well :)

from prebuild-install.

mathiask88 avatar mathiask88 commented on June 2, 2024

@reconbot Is this still a thing?

from prebuild-install.

reconbot avatar reconbot commented on June 2, 2024

Yeah, unless there's been new features I don't know about. This allows me to test our build pipeline and ensure we have binaries published and useable without having to build something to test prebuild-install.

from prebuild-install.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.