[bugfix] allow env overriding with launch options (#854)

This commit is contained in:
silentrald
2025-04-20 01:28:43 +08:00
committed by GitHub
parent b2357cd57f
commit e842cfa7eb
@@ -137,12 +137,11 @@ export abstract class AbstractLauncherService {
const envString = command.substring(0, index);
log.info("Parsing env string ", `"${envString}"`)
for (const [ key, value ] of Object.entries(parseEnvString(envString))) {
if (key in env) {
log.warn("Ignoring", `${key}=${value}`, "already set env launch command");
continue;
}
log.info("Injecting", `${key}="${value}"`, "to the env launch command");
log.info(
key in env ? "Overriding" : "Injecting",
`${key}="${value}"`,
"to the env launch command"
);
env[key] = value;
}