File tree Expand file tree Collapse file tree 2 files changed +3
-12
lines changed
Expand file tree Collapse file tree 2 files changed +3
-12
lines changed Original file line number Diff line number Diff line change @@ -12,7 +12,9 @@ default = ["clap"]
1212
1313[dependencies ]
1414clap = { version = " 3.1.6" , optional = true , features = [" derive" ] }
15+ current_platform = " 0.2.0"
1516dunce = " 1.0.1"
1617glob = " 0.3.0"
1718serde = { version = " 1.0.123" , features = [" derive" ] }
1819toml = " 0.5.8"
20+
Original file line number Diff line number Diff line change @@ -4,9 +4,7 @@ use crate::error::{Error, Result};
44use crate :: profile:: Profile ;
55use crate :: { utils, LocalizedConfig } ;
66use std:: ffi:: OsStr ;
7- use std:: io:: BufRead ;
87use std:: path:: { Path , PathBuf } ;
9- use std:: process:: Command ;
108
119#[ derive( Debug ) ]
1210pub struct Subcommand {
@@ -108,16 +106,7 @@ impl Subcommand {
108106 if artifacts. is_empty ( ) {
109107 artifacts. push ( Artifact :: Root ( package. clone ( ) ) ) ;
110108 }
111- let host_triple = Command :: new ( "rustc" )
112- . arg ( "-vV" )
113- . output ( )
114- . map_err ( |_| Error :: RustcNotFound ) ?
115- . stdout
116- . lines ( )
117- . map ( |l| l. unwrap ( ) )
118- . find ( |l| l. starts_with ( "host: " ) )
119- . map ( |l| l[ 6 ..] . to_string ( ) )
120- . ok_or ( Error :: RustcNotFound ) ?;
109+ let host_triple = current_platform:: CURRENT_PLATFORM . to_owned ( ) ;
121110 let profile = args. profile ( ) ;
122111 Ok ( Self {
123112 args,
You can’t perform that action at this time.
0 commit comments