From 93793ff300cca7b563c7b18a9282d05c65c82f5b Mon Sep 17 00:00:00 2001 From: Zontreck Date: Fri, 3 Nov 2023 01:17:41 -0700 Subject: [PATCH] Add environment to process spin up command --- lib/proton.dart | 11 ++++++----- 1 file changed, 6 insertions(+), 5 deletions(-) diff --git a/lib/proton.dart b/lib/proton.dart index 152826c..439e5b2 100644 --- a/lib/proton.dart +++ b/lib/proton.dart @@ -42,13 +42,14 @@ class ProtonState extends State { } else { await dir.create(recursive: true); } - Platform.environment.putIfAbsent( - "STEAM_COMPAT_CLIENT_INSTALL_PATH", () => "~/.steam"); - Platform.environment - .putIfAbsent("STEAM_COMPAT_DATA_PATH", () => dir.path); + Map env = Map(); + env.putIfAbsent( + "STEAM_COMPAT_CLIENT_INSTALL_PATH", () => "~/.steam"); + env.putIfAbsent("STEAM_COMPAT_DATA_PATH", () => dir.path); await Process.run( - "proton", ["run", "this_program_does_not_exist.exe"]); + "proton", ["run", "this_program_does_not_exist.exe"], + environment: env); }, ) ]),