Skip to content

Commit 823669d

Browse files
committed
Added remote platform config cleanup
1 parent c89c983 commit 823669d

File tree

1 file changed

+9
-0
lines changed

1 file changed

+9
-0
lines changed

flutter_workspace.py

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -247,6 +247,14 @@ def main():
247247
#
248248
# Load Remote Platforms
249249
#
250+
251+
# First, clear linked platforms
252+
configs_dir = os.path.join(os.getcwd(), 'configs')
253+
if os.path.exists(configs_dir):
254+
for filename in sorted(glob.glob(os.path.join(configs_dir, 'remote_*.json'))):
255+
print(f'Unlinking remote config file: {filename}')
256+
os.unlink(filename)
257+
# Setup remote platform
250258
app_folder = os.path.join(workspace, 'app')
251259
if args.remote:
252260
# comma-separated list of git repos
@@ -2943,6 +2951,7 @@ def get_engine_commit(version, hash_):
29432951
import pycurl
29442952
import certifi
29452953
from io import BytesIO
2954+
import glob
29462955

29472956
buffer = BytesIO()
29482957
c = pycurl.Curl()

0 commit comments

Comments
 (0)