@@ -14,8 +14,7 @@ use crate::core::build_steps::setup::Profile;
1414use crate :: core:: builder:: { Builder , Kind } ;
1515use crate :: core:: config:: Config ;
1616use crate :: core:: config:: target_selection:: { TargetSelectionList , target_selection_list} ;
17- use crate :: utils:: execution_context:: ExecutionContext ;
18- use crate :: { Build , DocTests , DryRun } ;
17+ use crate :: { Build , DocTests } ;
1918
2019#[ derive( Copy , Clone , Default , Debug , ValueEnum ) ]
2120pub enum Color {
@@ -210,8 +209,8 @@ impl Flags {
210209 HelpVerboseOnly :: try_parse_from ( normalize_args ( args) )
211210 {
212211 println ! ( "NOTE: updating submodules before printing available paths" ) ;
213- let ( flags, exec_ctx ) = Self :: parse ( & [ String :: from ( "build" ) ] ) ;
214- let config = Config :: parse ( flags, exec_ctx ) ;
212+ let flags = Self :: parse ( & [ String :: from ( "build" ) ] ) ;
213+ let config = Config :: parse ( flags) ;
215214 let build = Build :: new ( config) ;
216215 let paths = Builder :: get_help ( & build, subcommand) ;
217216 if let Some ( s) = paths {
@@ -229,13 +228,8 @@ impl Flags {
229228 feature = "tracing" ,
230229 instrument( level = "trace" , name = "Flags::parse" , skip_all, fields( args = ?args) )
231230 ) ]
232- pub fn parse ( args : & [ String ] ) -> ( Self , ExecutionContext ) {
233- let mut exec_ctx = ExecutionContext :: new ( ) ;
234- let flags = Flags :: parse_from ( normalize_args ( args) ) ;
235- exec_ctx. set_dry_run ( if flags. dry_run { DryRun :: UserSelected } else { DryRun :: Disabled } ) ;
236- exec_ctx. set_verbose ( flags. verbose ) ;
237- exec_ctx. set_fail_fast ( flags. cmd . fail_fast ( ) ) ;
238- ( flags, exec_ctx)
231+ pub fn parse ( args : & [ String ] ) -> Self {
232+ Flags :: parse_from ( normalize_args ( args) )
239233 }
240234}
241235
0 commit comments