Skip to content

Commit 60fa9ac

Browse files
committed
Disable interactive prompts in CI
1 parent 92b2972 commit 60fa9ac

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

src/bin/cargo-miri.rs

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
#![feature(inner_deref)]
22

3+
use std::env;
34
use std::fs::{self, File};
45
use std::io::{self, BufRead, Write};
56
use std::ops::Not;
@@ -435,7 +436,8 @@ fn in_cargo_miri() {
435436
test_sysroot_consistency();
436437

437438
// We always setup.
438-
let ask = subcommand != MiriCommand::Setup;
439+
// Disable interactive prompts in CI (GitHub Actions, Travis, AppVeyor, etc).
440+
let ask = subcommand != MiriCommand::Setup && env::var_os("CI").is_none();
439441
setup(ask);
440442
if subcommand == MiriCommand::Setup {
441443
// Stop here.

0 commit comments

Comments
 (0)