File tree Expand file tree Collapse file tree 1 file changed +0
-26
lines changed Expand file tree Collapse file tree 1 file changed +0
-26
lines changed Original file line number Diff line number Diff line change @@ -192,32 +192,6 @@ export async function activeToolchain(): Promise<string> {
192
192
} ) ;
193
193
}
194
194
195
- export async function rustVersion ( ) : Promise < string > {
196
- const pathToRustup = await rustupPath ( ) ;
197
- return await new Promise ( ( resolve , reject ) => {
198
- const execution = cp . spawn ( pathToRustup , [ 'show' , 'active-toolchain' ] , {
199
- stdio : [ 'ignore' , 'pipe' , 'pipe' ] ,
200
- cwd : os . homedir ( )
201
- } ) ;
202
- const rl = readline . createInterface ( { input : execution . stdout } ) ;
203
-
204
- let currToolchain : string | undefined = undefined ;
205
- rl . on ( 'line' , line => {
206
- const match = line . match ( TOOLCHAIN_PATTERN ) ;
207
- if ( match ) {
208
- currToolchain = match [ 1 ] ;
209
- }
210
- } ) ;
211
- execution . on ( 'exit' , ( exitCode , _ ) => {
212
- if ( exitCode === 1 && currToolchain )
213
- resolve ( currToolchain ) ;
214
- else
215
- reject ( new Error ( `exit code: ${ exitCode } .` ) ) ;
216
- } ) ;
217
-
218
- } ) ;
219
- }
220
-
221
195
/** Mirrors `project_model::sysroot::discover_sysroot_dir()` implementation*/
222
196
export async function getSysroot ( dir : string ) : Promise < string > {
223
197
const rustcPath = await getPathForExecutable ( "rustc" ) ;
You can’t perform that action at this time.
0 commit comments