Skip to content

Commit

Permalink
fix(importer): install electron-prebuilt-compile as devDep
Browse files Browse the repository at this point in the history
  • Loading branch information
anulman authored and MarshallOfSound committed Feb 7, 2017
1 parent 4942cb6 commit e80be32
Showing 1 changed file with 11 additions and 3 deletions.
14 changes: 11 additions & 3 deletions src/api/import.js
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ import path from 'path';
import { spawn as yarnOrNPMSpawn, hasYarn } from 'yarn-or-npm';

import initGit from '../init/init-git';
import { deps, devDeps } from '../init/init-npm';
import { deps, devDeps, exactDevDeps } from '../init/init-npm';

import asyncOra from '../util/ora-handler';
import { info, warn } from '../util/messages';
Expand Down Expand Up @@ -168,10 +168,18 @@ export default async (providedOptions = {}) => {

d('installing dependencies');
await installDepList(dir, deps);

d('installing devDependencies');
await installDepList(dir, devDeps, true);
d('installing electron-prebuilt-compile');
await installDepList(dir, [`electron-prebuilt-compile@${electronVersion || 'latest'}`], false, true);

d('installing exactDevDependencies');
await installDepList(dir, exactDevDeps.map((dep) => {
if (dep === 'electron-prebuild-compile') {
return `${dep}@${electronVersion || 'latest'}`;
}

return dep;
}), true, true);
});

packageJSON = await readPackageJSON(dir);
Expand Down

0 comments on commit e80be32

Please sign in to comment.