Skip to content

Commit 62e9f4e

Browse files
committed
Fix download_url
1 parent b217388 commit 62e9f4e

File tree

1 file changed

+6
-3
lines changed

1 file changed

+6
-3
lines changed

clang_tools/install.py

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -35,9 +35,12 @@ def clang_tidy_exist(version) -> bool:
3535

3636
def clang_tools_binary_url(tool, version) -> string:
3737
install_os = check_install_os()
38-
url = f"https://github.com/muttleyxd/clang-tools-static-binaries/releases/ \
39-
download/master-208096c1/{tool}-{version}_{install_os}-amd64".replace(" ", "")
40-
return url
38+
base_url = "https://github.com/muttleyxd/clang-tools-static-binaries/releases/download/master-208096c1"
39+
if install_os == "windows":
40+
download_url = f"{base_url}/{tool}-{version}_{install_os}-amd64.exe".replace(" ", "")
41+
else:
42+
download_url = f"{base_url}/{tool}-{version}_{install_os}-amd64".replace(" ", "")
43+
return download_url
4144

4245

4346
def install_clang_format(version, directory) -> None:

0 commit comments

Comments
 (0)