/// Forwards execution to the specified tool.
/// If the tool fails to start or is not found this process exits with
/// status code 101 the same as if the process has a panic!
Forwards execution to the specified tool.
If the tool fails to start or is not found this process exits with
status code 101 the same as if the process has a panic!
Forwards execution to the specified tool . If the tool fails to start or is not found this process exits with status code 101 the same as if the process has a panic!
pub fn rust_exec(self) -> ! {
        let path = match self.path() {
            Err(e) => {
                eprintln!("Failed to find tool: {}\n{}", self.name(), e);
                process::exit(101)
            }
            Ok(p) => p,
        };
        // Note: The first argument is the name of the binary (e.g. `rust-nm`)
        let args = env::args().skip(1);
        // Spawn the process and check if the process did spawn
        let status = match Command::new(path).args(args).status() {
            Err(e) => {
                eprintln!("Failed to execute tool: {}\n{}", self.name(), e);
                process::exit(101)
            }
            Ok(s) => s,
        };
        // Forward the exit code from the tool
        process::exit(status.code().unwrap_or(101));
    }
pub fn rust_exec ( self ) -> ! { let path = match self . path ( ) { Err ( e ) => { eprintln ! ( " \n " self name ( ) e ) ; process :: exit ( 101 ) } Ok ( p ) => p , } ; // Note: The first argument is the name of the binary (e.g. `rust-nm`) let args = env :: args ( ) . skip ( 1 ) ; // Spawn the process and check if the process did spawn let status = match Command :: new ( path ) . args ( args ) . status ( ) { Err ( e ) => { eprintln ! ( " \n " self name ( ) e ) ; process :: exit ( 101 ) } Ok ( s ) => s , } ; // Forward the exit code from the tool process :: exit ( status . code ( ) . unwrap_or ( 101 ) ) ; }
Forwards execution to the specified tool.
Forwards execution to the specified tool .
self