11use std:: env:: { consts:: EXE_SUFFIX , split_paths} ;
22use std:: ffi:: { OsStr , OsString } ;
33use std:: fmt;
4- use std:: io:: { self , Write } ;
4+ #[ cfg( any( test, feature = "test" ) ) ]
5+ use std:: io;
6+ use std:: io:: Write ;
57use std:: os:: windows:: ffi:: { OsStrExt , OsStringExt } ;
68use std:: path:: Path ;
79use std:: process:: Command ;
8- use std:: sync:: { Arc , LockResult , Mutex , MutexGuard } ;
10+ use std:: sync:: { Arc , Mutex } ;
11+ #[ cfg( any( test, feature = "test" ) ) ]
12+ use std:: sync:: { LockResult , MutexGuard } ;
913
1014use anyhow:: { anyhow, Context , Result } ;
1115use tracing:: { info, warn} ;
16+ use winreg:: enums:: { RegType , HKEY_CURRENT_USER , KEY_READ , KEY_WRITE } ;
17+ #[ cfg( any( test, feature = "test" ) ) ]
18+ use winreg:: types:: { FromRegValue , ToRegValue } ;
19+ use winreg:: { RegKey , RegValue } ;
1220
1321use super :: super :: errors:: * ;
1422use super :: common;
@@ -19,10 +27,6 @@ use crate::dist::TargetTriple;
1927use crate :: utils:: utils;
2028use crate :: utils:: Notification ;
2129
22- use winreg:: enums:: { RegType , HKEY_CURRENT_USER , KEY_READ , KEY_WRITE } ;
23- use winreg:: types:: { FromRegValue , ToRegValue } ;
24- use winreg:: { RegKey , RegValue } ;
25-
2630pub ( crate ) fn ensure_prompt ( process : & Process ) -> Result < ( ) > {
2731 writeln ! ( process. stdout( ) . lock( ) , ) ?;
2832 writeln ! ( process. stdout( ) . lock( ) , "Press the Enter key to continue." ) ?;
0 commit comments