atombuild / atom-build-npm-apm Goto Github PK
View Code? Open in Web Editor NEWNPM/APM plugin for atom-build
License: MIT License
NPM/APM plugin for atom-build
License: MIT License
When i run npm install
on my terminal, npm
installs dependencies
and devDependecies
.
When I run npm install
through this package, it only installs dependencies
. Can we either get it to install devDependencies
also or get a configuration for it?
I cannot get npm install
to run.
When I hit CTRLALTB, I get this error:
module.js:341
throw err;
^
Error: Cannot find module 'C:\Users\Danny\Dev\handmade-quake-js\node_modules\npm\bin\npm-cli.js'
at Function.Module._resolveFilename (module.js:339:15)
at Function.Module._load (module.js:290:25)
at Function.Module.runMain (module.js:447:10)
at startup (node.js:146:18)
at node.js:404:3
I made sure the only path I had in PATH
related to node or npm was my node path.
Any advice on how to get atom-build-npm-apm
to find my npm.cmd
file?
I got always this error, when I tried to run an npm script within my application.
npm ERR! node v7.4.0
npm ERR! npm v4.0.5
npm ERR! code ELIFECYCLE
npm ERR! {XXX} build-productive:gulp build-productive
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the {XXX} build-productive script 'gulp build-productive'.
npm ERR! Make sure you have the latest version of node.js and npm installed.
npm ERR! If you do, this is most likely a problem with the {XXX} package,
npm ERR! not with npm itself.
npm ERR! Tell the author that this fails on your system:
npm ERR! gulp build-productive
npm ERR! You can get information on how to open an issue for this project with:
npm ERR! npm bugs {XXX}
npm ERR! Or if that isn't available, you can get their info via:
npm ERR! npm owner ls {XXX}
npm ERR! There is likely additional logging output above.
npm ERR! Please include the following file with any support request:
npm ERR! /home/{XXX}/npm-debug.log
It took me some time, but I was able to figure out, that on my Ubuntu Machine the child process is spawned with:
npm run build-productive
witch calls my local installation of npm (see error).
But the process.env.NODE_PATH from Atom has been provided to the child process and I had to change this line:
const env = {FORCE_COLOR: '1', MOCHA_COLORS: '1', NPM_CONFIG_COLOR: 'always', NODE_ENV: ''};
to
const env = {FORCE_COLOR: '1', MOCHA_COLORS: '1', NPM_CONFIG_COLOR: 'always', NODE_ENV: '', NODE_PATH:'/usr/bin/node'};
I would consider it to be better, to be able to specify this within the configuration.
When package.json
not located in the project root folder, the builder does not find the package.json
.
How to tell the build system the directory where package.json
is located, when not in the project root folder ?
this did nothing until i looked in the code and i found that you need the engines
field in package.json
.
i think more people are confused since this is the first time i heard of this field.
Accidentally hitting F9 when it is an npm install is a bummer in a way.
OS: Mac OS X 10.11.5 (15F34)
Version: 0.12.0
Atom Version: 1.8.0
Recently either this package or the build package (idk) hangs up my editor window. When I hit cmd+alt+t
to display the targets the editor hangs. After a while a dialog pops up telling my that the editor window does not respond. Clicking 'wait' does not help. Tested it five time - same result everytime.
Maybe build-npm has a problem with my project structure. For this project it looks like this:
project root contains .git
directory (and other git stuff) and a subdirectory. That subdirectory contains the project-level package.json
.
When I run a npm script on windows, it only works if I run the "npm: default" task. If I run any other npm script, it fails to find npm.
Looking at your script source, on line 35, you have:
exec: (pkg.engines.node ? 'npm' : 'apm') + executableExtension,
Which guarantees the proper extension for the npm script on Windows.
On line 43:
exec: 'npm',
Which I assume is the culprit to make the other scripts fail.
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.