@@ -79,6 +79,27 @@ def bump_version_files(tag):
7979 out .writelines (new_lines )
8080 print (f"Updated { path } : { pretty_key } ={ tag } , version bumped by 1" )
8181
82+ def download_windows_dlls ():
83+ """Download bundled Windows runtime DLLs from latest CI run."""
84+ import subprocess , json
85+ repo = "processing-cpp/processing.cpp"
86+ r = subprocess .run (
87+ ["gh" , "run" , "list" , "--repo" , repo , "--workflow" , "build-cache.yml" ,
88+ "--status" , "success" , "--limit" , "1" , "--json" , "databaseId" ],
89+ capture_output = True , text = True )
90+ if r .returncode != 0 : return
91+ run_id = json .loads (r .stdout )[0 ]["databaseId" ]
92+ dest = Path (__file__ ).parent .parent / "libs" / "windows-x64"
93+ dest .mkdir (parents = True , exist_ok = True )
94+ result = subprocess .run (
95+ ["gh" , "run" , "download" , str (run_id ), "--repo" , repo ,
96+ "--name" , "windows-runtime-dlls" , "--dir" , str (dest )],
97+ capture_output = True , text = True )
98+ if result .returncode == 0 :
99+ print (f" windows runtime DLLs downloaded to { dest } " )
100+ else :
101+ print (f" WARNING: could not download windows runtime DLLs" )
102+
82103def trigger_and_wait_cache_build ():
83104 """Trigger a new build-cache CI run and wait for it to complete."""
84105 import subprocess , json , time
@@ -151,6 +172,27 @@ def download_cache_artifacts():
151172 print (f" { platform } : { files } " )
152173
153174
175+ def download_windows_dlls ():
176+ """Download bundled Windows runtime DLLs from latest CI run."""
177+ import subprocess , json
178+ repo = "processing-cpp/processing.cpp"
179+ r = subprocess .run (
180+ ["gh" , "run" , "list" , "--repo" , repo , "--workflow" , "build-cache.yml" ,
181+ "--status" , "success" , "--limit" , "1" , "--json" , "databaseId" ],
182+ capture_output = True , text = True )
183+ if r .returncode != 0 : return
184+ run_id = json .loads (r .stdout )[0 ]["databaseId" ]
185+ dest = Path (__file__ ).parent .parent / "libs" / "windows-x64"
186+ dest .mkdir (parents = True , exist_ok = True )
187+ result = subprocess .run (
188+ ["gh" , "run" , "download" , str (run_id ), "--repo" , repo ,
189+ "--name" , "windows-runtime-dlls" , "--dir" , str (dest )],
190+ capture_output = True , text = True )
191+ if result .returncode == 0 :
192+ print (f" windows runtime DLLs downloaded to { dest } " )
193+ else :
194+ print (f" WARNING: could not download windows runtime DLLs" )
195+
154196def trigger_and_wait_cache_build ():
155197 """Trigger a new build-cache CI run and wait for it to complete."""
156198 import subprocess , json , time
@@ -189,6 +231,7 @@ def main():
189231 bump_version_files (version )
190232 trigger_and_wait_cache_build ()
191233 download_cache_artifacts ()
234+ download_windows_dlls ()
192235 zip_name = "CppMode.zip"
193236 zip_path = os .path .join (OUTPUT_DIR , zip_name )
194237
0 commit comments