isaacs/npm — Issue #2195: Rebuild assumes it should runs make clean without assuming it should run make build
Author: jstewmon
Created: 2012-02-24 01:31:33+00:00
State: open

The fix for #1872 is a naughty one. It results in the deletion of files that are built and packaged by publishers who use make files, but don't specify npm scripts because they don't have C++ addons.

This affects `less` and `async` in my project.

If you jump the track to call clean, you should jump the track to call build. IMO, this was a bad call because it assumes that a makefile exists to work in conjunction with the npm build process.

This is especially bothersome because it can break an application during deployment for those following the advice to commit the `node_modules` directory and run `npm rebuild` on a server durning a deployment. That's how I've been doing my deployments, and it took me a whole day to figure out why the minified files that were in my repo were missing from my servers.