feat(andax/nvidia.rhai): Automatically fetch new CUDA versions (#4514) (#4518)

(cherry picked from commit 438d83f22c)

Signed-off-by: Gilver <rockgrub@disroot.org>
Co-authored-by: Gilver <rockgrub@disroot.org>
This commit is contained in:
Raboneko
2025-04-29 04:48:56 -07:00
committed by GitHub
parent 4a54ad7277
commit 653dae39d5
+4 -3
View File
@@ -2,9 +2,10 @@
// This module is used to parse the NVIDIA website for the latest driver version
fn nvidia_component_list() {
let series = "12.8.1";
let url = `https://developer.download.nvidia.com/compute/cuda/redist/redistrib_${series}.json`;
return get(url).json();
let url = "https://developer.download.nvidia.com/compute/cuda/redist/";
let matches = find_all("redistrib_[\\d.]+.json", get(url));
let series = `${url}${matches[matches.len - 1][0]}`;
return get(series).json();
}
fn nvidia_component_version(component) {
let components = nvidia_component_list();