Add runnable env support.
This commit is contained in:
@@ -5,6 +5,8 @@ export type UpdatesChannel = "stable" | "nightly";
|
||||
|
||||
export const NIGHTLY_TAG = "nightly";
|
||||
|
||||
export type RunnableEnvCfg = Record<string, string> | [{ mask?: string, env: Record<string, string>; }]
|
||||
|
||||
export class Config {
|
||||
readonly extensionId = "matklad.rust-analyzer";
|
||||
|
||||
@@ -114,6 +116,10 @@ export class Config {
|
||||
return this.get<string | undefined>("cargoRunner");
|
||||
}
|
||||
|
||||
get runnableEnv() {
|
||||
return this.get<RunnableEnvCfg | undefined>("runnableEnv");
|
||||
}
|
||||
|
||||
get debug() {
|
||||
// "/rustc/<id>" used by suggestions only.
|
||||
const { ["/rustc/<id>"]: _, ...sourceFileMap } = this.get<Record<string, string>>("debug.sourceFileMap");
|
||||
|
||||
Reference in New Issue
Block a user