Skip to content

Commit e2d0867

Browse files
committed
Conditionally add -D to gclient sync.
1 parent d40fc7c commit e2d0867

1 file changed

Lines changed: 2 additions & 1 deletion

File tree

build/build.js

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,8 @@ async function createProject() {
4242
process.chdir(kDawnPath);
4343
fs.copyFileSync('scripts/standalone-with-node.gclient', '.gclient');
4444
await execute('gclient', ['metrics', '--opt-out']);
45-
await execute('gclient', ['sync', '-D']);
45+
// add -D only if gclieny sync was run before.
46+
await execute('gclient', ['sync', ...addElemIf(exists('.gclient_entries'), '-D')]);
4647
if (exists(kBuildPath)) {
4748
fs.rmSync(kBuildPath, {recursive: true});
4849
}

0 commit comments

Comments
 (0)