Skip to content
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

[6.x] Use execFile instead of exec when installing deps in build (#16587) #16589

Merged
merged 1 commit into from
Feb 8, 2018
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 4 additions & 3 deletions tasks/build/install_dependencies.js
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import { exec } from 'child_process';
import { execFile } from 'child_process';
module.exports = function (grunt) {
grunt.registerTask('_build:installDependencies', function () {
// We rely on a local version of Yarn that contains the bugfix from
Expand All @@ -9,8 +9,9 @@ module.exports = function (grunt) {
// We're using `pure-lockfile` instead of `frozen-lockfile` because we
// rewrite `link:` dependencies to `file:` dependencies earlier in the
// build. This means the lockfile won't be consistent, so instead of
// verifying it, we just skip writing a new lockfile.
exec(`${yarn} --production --ignore-optional --pure-lockfile`, {
// verifying it, we just skip writing a new lockfile. However, this does
// still use the existing lockfile for dependency resolution.
execFile(yarn, ['--production', '--ignore-optional', '--pure-lockfile'], {
cwd: grunt.config.process('<%= root %>/build/kibana')
}, this.async());
});
Expand Down