win32: Add portable msvc downloader

This commit is contained in:
doyle 2022-05-04 23:33:40 +10:00
parent 6ac89661f0
commit 92afd0282b
4 changed files with 661 additions and 462 deletions

View File

@ -1,13 +0,0 @@
@echo off
set dest_dir="%~dp0Windows_Symbols_PDBs"
set symchk="C:\Program Files (x86)\Windows Kits\10\Debuggers\x64\symchk.exe"
if not exist %symchk% (
echo Symchk binary not found but is required to run script [path=%symchk%]
exit /b 1
)
if not exist %dest_dir% mkdir %dest_dir%
echo Downloading to %dest_dir% with %symchk%
%symchk% /r C:\Windows /s srv*%dest_dir%*https://msdl.microsoft.com/download/symbols
goto :eof

288
Tools/portable-msvc.py Normal file
View File

@ -0,0 +1,288 @@
#!/usr/bin/env python3
import io
import os
import sys
import json
import shutil
import hashlib
import zipfile
import tempfile
import argparse
import subprocess
import urllib.request
from pathlib import Path
OUTPUT = Path("msvc") # output folder
# other architectures may work or may not - not really tested
HOST = "x64" # or x86
TARGET = "x64" # or x86, arm, arm64
MANIFEST_URL = "https://aka.ms/vs/17/release/channel"
def download(url):
with urllib.request.urlopen(url) as res:
return res.read()
def download_progress(url, check, name, f):
data = io.BytesIO()
with urllib.request.urlopen(url) as res:
total = int(res.headers["Content-Length"])
size = 0
while True:
block = res.read(1<<20)
if not block:
break
f.write(block)
data.write(block)
size += len(block)
perc = size * 100 // total
print(f"\r{name} ... {perc}%", end="")
print()
data = data.getvalue()
digest = hashlib.sha256(data).hexdigest()
if check.lower() != digest:
exit(f"Hash mismatch for f{pkg}")
return data
# super crappy msi format parser just to find required .cab files
def get_msi_cabs(msi):
index = 0
while True:
index = msi.find(b".cab", index+4)
if index < 0:
return
yield msi[index-32:index+4].decode("ascii")
def first(items, cond):
return next(item for item in items if cond(item))
### parse command-line arguments
ap = argparse.ArgumentParser()
ap.add_argument("--show-versions", const=True, action="store_const", help="Show available MSVC and Windows SDK versions")
ap.add_argument("--accept-license", const=True, action="store_const", help="Automatically accept license")
ap.add_argument("--msvc-version", help="Get specific MSVC version")
ap.add_argument("--sdk-version", help="Get specific Windows SDK version")
args = ap.parse_args()
### get main manifest
manifest = json.loads(download(MANIFEST_URL))
### download VS manifest
vs = first(manifest["channelItems"], lambda x: x["id"] == "Microsoft.VisualStudio.Manifests.VisualStudio")
payload = vs["payloads"][0]["url"]
vsmanifest = json.loads(download(payload))
### find MSVC & WinSDK versions
packages = {}
for p in vsmanifest["packages"]:
packages.setdefault(p["id"].lower(), []).append(p)
msvc = {}
sdk = {}
for pid,p in packages.items():
if pid.startswith("Microsoft.VisualStudio.Component.VC.".lower()) and pid.endswith(".x86.x64".lower()):
pver = ".".join(pid.split(".")[4:6])
if pver[0].isnumeric():
msvc[pver] = pid
elif pid.startswith("Microsoft.VisualStudio.Component.Windows10SDK.".lower()) or \
pid.startswith("Microsoft.VisualStudio.Component.Windows11SDK.".lower()):
pver = pid.split(".")[-1]
if pver.isnumeric():
sdk[pver] = pid
if args.show_versions:
print("MSVC versions:", " ".join(sorted(msvc.keys())))
print("Windows SDK versions:", " ".join(sorted(sdk.keys())))
exit(0)
msvc_ver = args.msvc_version or max(sorted(msvc.keys()))
sdk_ver = args.sdk_version or max(sorted(sdk.keys()))
if msvc_ver in msvc:
msvc_pid = msvc[msvc_ver]
msvc_ver = ".".join(msvc_pid.split(".")[4:-2])
else:
exit(f"Unknown MSVC version: f{args.msvc_version}")
if sdk_ver in sdk:
sdk_pid = sdk[sdk_ver]
else:
exit(f"Unknown Windows SDK version: f{args.sdk_version}")
print(f"Downloading MSVC v{msvc_ver} and Windows SDK v{sdk_ver}")
### agree to license
tools = first(manifest["channelItems"], lambda x: x["id"] == "Microsoft.VisualStudio.Product.BuildTools")
resource = first(tools["localizedResources"], lambda x: x["language"] == "en-us")
license = resource["license"]
if not args.accept_license:
accept = input(f"Do you accept Visual Studio license at {license} [Y/N] ? ")
if not accept or accept[0].lower() != "y":
exit(0)
OUTPUT.mkdir(exist_ok=True)
total_download = 0
### download MSVC
msvc_packages = [
# MSVC binaries
f"microsoft.vc.{msvc_ver}.tools.host{HOST}.target{TARGET}.base",
f"microsoft.vc.{msvc_ver}.tools.host{HOST}.target{TARGET}.res.base",
# MSVC headers
f"microsoft.vc.{msvc_ver}.crt.headers.base",
# MSVC libs
f"microsoft.vc.{msvc_ver}.crt.{TARGET}.desktop.base",
f"microsoft.vc.{msvc_ver}.crt.{TARGET}.store.base",
# MSVC runtime source
f"microsoft.vc.{msvc_ver}.crt.source.base",
# ASAN
f"microsoft.vc.{msvc_ver}.asan.headers.base",
f"microsoft.vc.{msvc_ver}.asan.{TARGET}.base",
# MSVC redist
#f"microsoft.vc.{msvc_ver}.crt.redist.x64.base",
]
for pkg in msvc_packages:
p = first(packages[pkg], lambda p: p.get("language") in (None, "en-US"))
for payload in p["payloads"]:
with tempfile.TemporaryFile() as f:
data = download_progress(payload["url"], payload["sha256"], pkg, f)
total_download += len(data)
with zipfile.ZipFile(f) as z:
for name in z.namelist():
if name.startswith("Contents/"):
out = OUTPUT / Path(name).relative_to("Contents")
out.parent.mkdir(parents=True, exist_ok=True)
out.write_bytes(z.read(name))
### download Windows SDK
sdk_packages = [
# Windows SDK tools (like rc.exe & mt.exe)
f"Windows SDK for Windows Store Apps Tools-x86_en-us.msi",
# Windows SDK headers
f"Windows SDK for Windows Store Apps Headers-x86_en-us.msi",
# Windows SDK libs
f"Windows SDK for Windows Store Apps Libs-x86_en-us.msi",
f"Windows SDK Desktop Libs {TARGET}-x86_en-us.msi",
# CRT headers & libs
f"Universal CRT Headers Libraries and Sources-x86_en-us.msi",
# CRT redist
#"Universal CRT Redistributable-x86_en-us.msi",
]
with tempfile.TemporaryDirectory() as d:
dst = Path(d)
sdk_pkg = packages[sdk_pid][0]
sdk_pkg = packages[first(sdk_pkg["dependencies"], lambda x: True).lower()][0]
msi = []
cabs = []
# download msi files
for pkg in sdk_packages:
payload = first(sdk_pkg["payloads"], lambda p: p["fileName"] == f"Installers\\{pkg}")
msi.append(dst / pkg)
with open(dst / pkg, "wb") as f:
data = download_progress(payload["url"], payload["sha256"], pkg, f)
total_download += len(data)
cabs += list(get_msi_cabs(data))
# download .cab files
for pkg in cabs:
payload = first(sdk_pkg["payloads"], lambda p: p["fileName"] == f"Installers\\{pkg}")
with open(dst / pkg, "wb") as f:
download_progress(payload["url"], payload["sha256"], pkg, f)
print("Unpacking msi files...")
# run msi installers
for m in msi:
subprocess.check_call(["msiexec.exe", "/a", m, "/quiet", "/qn", f"TARGETDIR={OUTPUT.resolve()}"])
### versions
msvcv = list((OUTPUT / "VC/Tools/MSVC").glob("*"))[0].name
sdkv = list((OUTPUT / "Windows Kits/10/bin").glob("*"))[0].name
# place debug CRT runtime into MSVC folder (not what real Visual Studio installer does... but is reasonable)
dst = str(OUTPUT / "VC/Tools/MSVC" / msvcv / f"bin/Host{HOST}/{TARGET}")
pkg = "microsoft.visualcpp.runtimedebug.14"
dbg = packages[pkg][0]
payload = first(dbg["payloads"], lambda p: p["fileName"] == "cab1.cab")
try:
with tempfile.TemporaryFile(suffix=".cab", delete=False) as f:
data = download_progress(payload["url"], payload["sha256"], pkg, f)
total_download += len(data)
subprocess.check_call(["expand.exe", f.name, "-F:*", dst], stdout=subprocess.DEVNULL, stderr=subprocess.DEVNULL)
finally:
os.unlink(f.name)
### cleanup
shutil.rmtree(OUTPUT / "Common7", ignore_errors=True)
for f in ["Auxiliary", f"lib/{TARGET}/store", f"lib/{TARGET}/uwp"]:
shutil.rmtree(OUTPUT / "VC/Tools/MSVC" / msvcv / f)
for f in OUTPUT.glob("*.msi"):
f.unlink()
for f in ["Catalogs", "DesignTime", f"bin/{sdkv}/chpe", f"Lib/{sdkv}/ucrt_enclave"]:
shutil.rmtree(OUTPUT / "Windows Kits/10" / f, ignore_errors=True)
for arch in ["x86", "x64", "arm", "arm64"]:
if arch != TARGET:
shutil.rmtree(OUTPUT / "VC/Tools/MSVC" / msvcv / f"bin/Host{arch}", ignore_errors=True)
shutil.rmtree(OUTPUT / "Windows Kits/10/bin" / sdkv / arch)
shutil.rmtree(OUTPUT / "Windows Kits/10/Lib" / sdkv / "ucrt" / arch)
shutil.rmtree(OUTPUT / "Windows Kits/10/Lib" / sdkv / "um" / arch)
### setup.bat
SETUP = f"""@echo off
set ROOT=%~dp0
set MSVC_VERSION={msvcv}
set MSVC_HOST=Host{HOST}
set MSVC_ARCH={TARGET}
set SDK_VERSION={sdkv}
set SDK_ARCH={TARGET}
set MSVC_ROOT=%ROOT%VC\\Tools\\MSVC\\%MSVC_VERSION%
set SDK_INCLUDE=%ROOT%Windows Kits\\10\\Include\\%SDK_VERSION%
set SDK_LIBS=%ROOT%Windows Kits\\10\\Lib\\%SDK_VERSION%
set VCToolsInstallDir=%MSVC_ROOT%\\
set PATH=%MSVC_ROOT%\\bin\\%MSVC_HOST%\\%MSVC_ARCH%;%ROOT%Windows Kits\\10\\bin\\%SDK_VERSION%\\%SDK_ARCH%\\ucrt;%PATH%
set INCLUDE=%MSVC_ROOT%\\include;%SDK_INCLUDE%\\ucrt;%SDK_INCLUDE%\\shared;%SDK_INCLUDE%\\um;%SDK_INCLUDE%\\winrt;%SDK_INCLUDE%\\cppwinrt
set LIB=%MSVC_ROOT%\\lib\\%MSVC_ARCH%;%SDK_LIBS%\\ucrt\\%SDK_ARCH%;%SDK_LIBS%\\um\\%SDK_ARCH%
"""
with open(OUTPUT / "setup.bat", "w") as f:
print(SETUP, file=f)
print(f"Total downloaded: {total_download>>20} MB")
print("Done!")

View File

@ -1,8 +1,6 @@
@echo off @echo off
setlocal EnableDelayedExpansion setlocal EnableDelayedExpansion
call win32_install_config.bat
REM ---------------------------------------------------------------------------- REM ----------------------------------------------------------------------------
REM Setup Folder Locations REM Setup Folder Locations
REM ---------------------------------------------------------------------------- REM ----------------------------------------------------------------------------
@ -105,26 +103,24 @@ REM Download & verify the tools we want for development
REM ---------------------------------------------------------------------------- REM ----------------------------------------------------------------------------
REM Wezterm REM Wezterm
REM ---------------------------------------------------------------------------- REM ----------------------------------------------------------------------------
if !install_wezterm! == 1 ( set wezterm_sha256=c634e98fa9715766bbb00cbc3c8a23d1d558c8cd5716ad2efca45ed4e0ef82f9
set wezterm_sha256=c634e98fa9715766bbb00cbc3c8a23d1d558c8cd5716ad2efca45ed4e0ef82f9 set wezterm_exe_sha256=b9b5bae20d0679127ca0c4da276dff3b7b32310bfbfaede26a9b8ecb55e295ce
set wezterm_exe_sha256=b9b5bae20d0679127ca0c4da276dff3b7b32310bfbfaede26a9b8ecb55e295ce set wezterm_version=20220408-101518-b908e2dd
set wezterm_version=20220408-101518-b908e2dd
set wezterm_zip=!downloads_dir!\win32_wezterm-!wezterm_version!.zip set wezterm_zip=!downloads_dir!\win32_wezterm-!wezterm_version!.zip
set wezterm_dir=!tools_dir!\wezterm-!wezterm_version! set wezterm_dir=!tools_dir!\wezterm-!wezterm_version!
set wezterm_exe=!wezterm_dir!\wezterm-gui.exe set wezterm_exe=!wezterm_dir!\wezterm-gui.exe
if not exist "!wezterm_exe!" ( if not exist "!wezterm_exe!" (
call :DownloadFile https://github.com/wez/wezterm/releases/download/!wezterm_version!/WezTerm-windows-!wezterm_version!.zip "!wezterm_zip!" || exit /B call :DownloadFile https://github.com/wez/wezterm/releases/download/!wezterm_version!/WezTerm-windows-!wezterm_version!.zip "!wezterm_zip!" || exit /B
call :VerifyZipSHA256 "!wezterm_zip!" "!wezterm_sha256!" || exit /B call :VerifyZipSHA256 "!wezterm_zip!" "!wezterm_sha256!" || exit /B
call :Unzip "!wezterm_zip!" "!wezterm_dir!" || exit /B call :Unzip "!wezterm_zip!" "!wezterm_dir!" || exit /B
call :Move "!wezterm_dir!\wezterm-windows-!wezterm_version!" "!wezterm_dir!" || exit /B call :Move "!wezterm_dir!\wezterm-windows-!wezterm_version!" "!wezterm_dir!" || exit /B
)
call :VerifyFileSHA256 "!wezterm_exe!" "!wezterm_version!" "!wezterm_exe_sha256!" || exit /B
call :CopyAndAlwaysOverwriteFile "!install_dir!\wezterm.lua" "!wezterm_dir!\wezterm.lua" || exit /B
) )
call :VerifyFileSHA256 "!wezterm_exe!" "!wezterm_version!" "!wezterm_exe_sha256!" || exit /B
call :CopyAndAlwaysOverwriteFile "!install_dir!\wezterm.lua" "!wezterm_dir!\wezterm.lua" || exit /B
REM ---------------------------------------------------------------------------- REM ----------------------------------------------------------------------------
REM Jetbrains Mono Font REM Jetbrains Mono Font
REM ---------------------------------------------------------------------------- REM ----------------------------------------------------------------------------
@ -150,41 +146,38 @@ REM ----------------------------------------------------------------------------
REM ---------------------------------------------------------------------------- REM ----------------------------------------------------------------------------
REM Git REM Git
REM ---------------------------------------------------------------------------- REM ----------------------------------------------------------------------------
if !install_git! == 1 ( set git_sha256=bc030848e282d49e562ae2392a72501cf539322ad06ffe4cea8cf766f148dfe8
set git_sha256=bc030848e282d49e562ae2392a72501cf539322ad06ffe4cea8cf766f148dfe8 set git_exe_sha256=ae463cad04c2b15fc91de68ab096933ec08c44752e205aebd7d64c3a482df62d
set git_exe_sha256=ae463cad04c2b15fc91de68ab096933ec08c44752e205aebd7d64c3a482df62d set git_version=2.33.0
set git_version=2.33.0
set git_zip=!downloads_dir!\win32_git_!git_version!.7z.exe set git_zip=!downloads_dir!\win32_git_!git_version!.7z.exe
REM Do *NOT* use an environment variable named git_dir as this will conflict REM Do *NOT* use an environment variable named git_dir as this will conflict
REM with git reading it as the directory to base off all git operations. REM with git reading it as the directory to base off all git operations.
set git_install_dir=!tools_dir!\PortableGit-!git_version! set git_install_dir=!tools_dir!\PortableGit-!git_version!
set git_exe=!git_install_dir!\cmd\git.exe set git_exe=!git_install_dir!\cmd\git.exe
if not exist "!git_exe!" ( if not exist "!git_exe!" (
call :DownloadFile "https://github.com/git-for-windows/git/releases/download/v!git_version!.windows.2/PortableGit-!git_version!.2-64-bit.7z.exe" "!git_zip!" || exit /B call :DownloadFile "https://github.com/git-for-windows/git/releases/download/v!git_version!.windows.2/PortableGit-!git_version!.2-64-bit.7z.exe" "!git_zip!" || exit /B
call :VerifyZipSHA256 "!git_zip!" "!git_sha256!" || exit /B call :VerifyZipSHA256 "!git_zip!" "!git_sha256!" || exit /B
call :Unzip "!git_zip!" "!git_install_dir!" || exit /B call :Unzip "!git_zip!" "!git_install_dir!" || exit /B
)
call :VerifyFileSHA256 "!git_exe!" "!git_version!" "!git_exe_sha256!" || exit /B
) )
call :VerifyFileSHA256 "!git_exe!" "!git_version!" "!git_exe_sha256!" || exit /B
REM ---------------------------------------------------------------------------- REM ----------------------------------------------------------------------------
REM LLVM/Clang REM LLVM/Clang
REM ---------------------------------------------------------------------------- REM ----------------------------------------------------------------------------
if !install_llvm_clang! == 1 ( set llvm_exe_sha256=9f0748de7f946c210a030452de226986bab46a0121d7236ea0e7b5079cb6dfef
set llvm_exe_sha256=9f0748de7f946c210a030452de226986bab46a0121d7236ea0e7b5079cb6dfef set llvm_version=12.0.1
set llvm_version=12.0.1
set llvm_zip=!downloads_dir!\win32_llvm_x64_v!llvm_version!.exe set llvm_zip=!downloads_dir!\win32_llvm_x64_v!llvm_version!.exe
set llvm_dir=!tools_dir!\llvm-!llvm_version! set llvm_dir=!tools_dir!\llvm-!llvm_version!
set llvm_exe=!llvm_dir!\bin\clang.exe set llvm_exe=!llvm_dir!\bin\clang.exe
set llvm_gpg_key=!downloads_dir!\llvm-tstellar-gpg-key.asc set llvm_gpg_key=!downloads_dir!\llvm-tstellar-gpg-key.asc
set llvm_gpg_sig=!llvm_zip!.sig set llvm_gpg_sig=!llvm_zip!.sig
if not exist "!llvm_exe!" ( if not exist "!llvm_exe!" (
call :DownloadFile "https://github.com/llvm/llvm-project/releases/download/llvmorg-9.0.1/tstellar-gpg-key.asc" "!llvm_gpg_key!" || exit /B call :DownloadFile "https://github.com/llvm/llvm-project/releases/download/llvmorg-9.0.1/tstellar-gpg-key.asc" "!llvm_gpg_key!" || exit /B
call :DownloadFile "https://github.com/llvm/llvm-project/releases/download/llvmorg-!llvm_version!/LLVM-!llvm_version!-win64.exe.sig" "!llvm_gpg_sig!" || exit /B call :DownloadFile "https://github.com/llvm/llvm-project/releases/download/llvmorg-!llvm_version!/LLVM-!llvm_version!-win64.exe.sig" "!llvm_gpg_sig!" || exit /B
call :DownloadFile "https://github.com/llvm/llvm-project/releases/download/llvmorg-!llvm_version!/LLVM-!llvm_version!-win64.exe" "!llvm_zip!" || exit /B call :DownloadFile "https://github.com/llvm/llvm-project/releases/download/llvmorg-!llvm_version!/LLVM-!llvm_version!-win64.exe" "!llvm_zip!" || exit /B
@ -192,324 +185,317 @@ if !install_llvm_clang! == 1 (
gpg --import "!llvm_gpg_key!" || exit /B gpg --import "!llvm_gpg_key!" || exit /B
gpg --verify "!llvm_gpg_sig!" "!llvm_zip!" || exit /B gpg --verify "!llvm_gpg_sig!" "!llvm_zip!" || exit /B
call :Unzip "!llvm_zip!" "!llvm_dir!" || exit /B call :Unzip "!llvm_zip!" "!llvm_dir!" || exit /B
)
if !install_gvim! == 1 (
set clang_format_py_sha256=36ba7aa047f8a8ac8fdc278aaa733de801cc84dea60a4210973fd3e4f0d2a330
set vim_clang_format=!vim_dir!\clang-format.py
call :CopyAndAlwaysOverwriteFile "!llvm_dir!\share\clang\clang-format.py" "!vim_clang_format!" || exit /B
call :VerifyFileSHA256 "!vim_clang_format!" "!llvm_version!" "!clang_format_py_sha256!" || exit /B
)
set llvm_bin_dir=!llvm_dir!\bin
call :VerifyFileSHA256 "!llvm_exe!" "!llvm_version!" "!llvm_exe_sha256!" || exit /B
) )
REM Clang Format
set clang_format_py_sha256=36ba7aa047f8a8ac8fdc278aaa733de801cc84dea60a4210973fd3e4f0d2a330
set vim_clang_format=!vim_dir!\clang-format.py
call :CopyAndAlwaysOverwriteFile "!llvm_dir!\share\clang\clang-format.py" "!vim_clang_format!" || exit /B
call :VerifyFileSHA256 "!vim_clang_format!" "!llvm_version!" "!clang_format_py_sha256!" || exit /B
set llvm_bin_dir=!llvm_dir!\bin
call :VerifyFileSHA256 "!llvm_exe!" "!llvm_version!" "!llvm_exe_sha256!" || exit /B
REM ------------------------------------------------------------------------ REM ------------------------------------------------------------------------
REM MinGW64 REM MinGW64
REM ------------------------------------------------------------------------ REM ------------------------------------------------------------------------
if !install_mingw64! == 1 ( set mingw_sha256=853970527b5de4a55ec8ca4d3fd732c00ae1c69974cc930c82604396d43e79f8
set mingw_sha256=853970527b5de4a55ec8ca4d3fd732c00ae1c69974cc930c82604396d43e79f8 set mingw_exe_sha256=c5f0953f7a71ddcdf0852e1e44a43cef9b8fe121beba4d4202bfe6d405de47c0
set mingw_exe_sha256=c5f0953f7a71ddcdf0852e1e44a43cef9b8fe121beba4d4202bfe6d405de47c0 set mingw_version=8.1.0
set mingw_version=8.1.0
set mingw_zip=!downloads_dir!\win32_mingw64-posix-seg-rt_v6-rev0!mingw_version!.7z set mingw_zip=!downloads_dir!\win32_mingw64-posix-seg-rt_v6-rev0!mingw_version!.7z
set mingw_dir=!tools_dir!\mingw64-posix-seh-rt_v6-rev0-!mingw_version! set mingw_dir=!tools_dir!\mingw64-posix-seh-rt_v6-rev0-!mingw_version!
set mingw_bin_dir=!mingw_dir!\bin set mingw_bin_dir=!mingw_dir!\bin
set mingw_exe=!mingw_bin_dir!\gcc.exe set mingw_exe=!mingw_bin_dir!\gcc.exe
if not exist "!mingw_exe!" ( if not exist "!mingw_exe!" (
call :DownloadFile \"https://sourceforge.net/projects/mingw-w64/files/Toolchains targetting Win64/Personal Builds/mingw-builds/!mingw_version!/threads-posix/seh/x86_64-!mingw_version!-release-posix-seh-rt_v6-rev0.7z\" !mingw_zip! || exit /B call :DownloadFile \"https://sourceforge.net/projects/mingw-w64/files/Toolchains targetting Win64/Personal Builds/mingw-builds/!mingw_version!/threads-posix/seh/x86_64-!mingw_version!-release-posix-seh-rt_v6-rev0.7z\" !mingw_zip! || exit /B
call :VerifyZipSHA256 !mingw_zip! !mingw_sha256! || exit /B call :VerifyZipSHA256 !mingw_zip! !mingw_sha256! || exit /B
call :Unzip !mingw_zip! !mingw_dir! || exit /B call :Unzip !mingw_zip! !mingw_dir! || exit /B
call :Move !mingw_dir!\mingw64 !mingw_dir! || exit /B call :Move !mingw_dir!\mingw64 !mingw_dir! || exit /B
)
call :VerifyFileSHA256 "!mingw_exe!" "!mingw_version!" "!mingw_exe_sha256!" || exit /B
) )
call :VerifyFileSHA256 "!mingw_exe!" "!mingw_version!" "!mingw_exe_sha256!" || exit /B
REM ---------------------------------------------------------------------------- REM ----------------------------------------------------------------------------
REM nodejs REM nodejs
REM ---------------------------------------------------------------------------- REM ----------------------------------------------------------------------------
if !install_nodejs! == 1 ( set nodejs_sha256=f7b0e8b0bfcfad7d62eba16fa4db9f085983c12c661bd4c66d8e3bd783befa65
set nodejs_sha256=f7b0e8b0bfcfad7d62eba16fa4db9f085983c12c661bd4c66d8e3bd783befa65 set nodejs_exe_sha256=7f33cbe04cb2940427e6dd97867c1fcf3ddd60911d2ae0260da3cab9f6ea6365
set nodejs_exe_sha256=7f33cbe04cb2940427e6dd97867c1fcf3ddd60911d2ae0260da3cab9f6ea6365 set nodejs_version=16.7.0
set nodejs_version=16.7.0
set nodejs_zip=!downloads_dir!\nodejs-!nodejs_version!-win-x64.7z set nodejs_zip=!downloads_dir!\nodejs-!nodejs_version!-win-x64.7z
set nodejs_dir=!tools_dir!\nodejs-!nodejs_version! set nodejs_dir=!tools_dir!\nodejs-!nodejs_version!
set nodejs_exe=!nodejs_dir!\node.exe set nodejs_exe=!nodejs_dir!\node.exe
if not exist "!nodejs_exe!" ( if not exist "!nodejs_exe!" (
call :DownloadFile "https://nodejs.org/dist/v!nodejs_version!/node-v!nodejs_version!-win-x64.7z" "!nodejs_zip!" || exit /B call :DownloadFile "https://nodejs.org/dist/v!nodejs_version!/node-v!nodejs_version!-win-x64.7z" "!nodejs_zip!" || exit /B
call :VerifyZipSHA256 "!nodejs_zip!" "!nodejs_sha256!" || exit /B call :VerifyZipSHA256 "!nodejs_zip!" "!nodejs_sha256!" || exit /B
call :Unzip "!nodejs_zip!" "!nodejs_dir!" || exit /B call :Unzip "!nodejs_zip!" "!nodejs_dir!" || exit /B
call :Move "!nodejs_dir!\node-v!nodejs_version!-win-x64" "!nodejs_dir!" || exit /B call :Move "!nodejs_dir!\node-v!nodejs_version!-win-x64" "!nodejs_dir!" || exit /B
)
call :VerifyFileSHA256 "!nodejs_exe!" "!nodejs_version!" "!nodejs_exe_sha256!" || exit /B
) )
call :VerifyFileSHA256 "!nodejs_exe!" "!nodejs_version!" "!nodejs_exe_sha256!" || exit /B
REM ---------------------------------------------------------------------------- REM ----------------------------------------------------------------------------
REM Python REM Python
REM ---------------------------------------------------------------------------- REM ----------------------------------------------------------------------------
if !install_python3! == 1 ( set python_sha256=93cc3db75dffb4d56b9f64af43294f130f2c222a66de7a1325d0ce8f1ed62e26
set python_sha256=93cc3db75dffb4d56b9f64af43294f130f2c222a66de7a1325d0ce8f1ed62e26 set python_exe_sha256=9042daa88b2d3879a51bfabc2d90d4a56da05ebf184b6492a22a46fdc1c936a4
set python_exe_sha256=9042daa88b2d3879a51bfabc2d90d4a56da05ebf184b6492a22a46fdc1c936a4 set python_version=3.9.0.2dot
set python_version=3.9.0.2dot set python_version_nodot=3902
set python_version_nodot=3902 set python_version_dot=3.9.0
set python_version_dot=3.9.0
set python_zip=!downloads_dir!\win32_Winpython64-!python_version!.zip set python_zip=!downloads_dir!\win32_Winpython64-!python_version!.zip
set python_dir=!tools_dir!\Winpython64-!python_version_nodot! set python_dir=!tools_dir!\Winpython64-!python_version_nodot!
set python_exe=!python_dir!\python-3.9.0.amd64\python.exe set python_exe=!python_dir!\python-3.9.0.amd64\python.exe
if not exist "!python_exe!" ( if not exist "!python_exe!" (
call :DownloadFile "https://github.com/winpython/winpython/releases/download/3.0.20201028/Winpython64-!python_version!.exe" "!python_zip!" || exit /B call :DownloadFile "https://github.com/winpython/winpython/releases/download/3.0.20201028/Winpython64-!python_version!.exe" "!python_zip!" || exit /B
call :VerifyZipSHA256 "!python_zip!" "!python_sha256!" || exit /B call :VerifyZipSHA256 "!python_zip!" "!python_sha256!" || exit /B
call :Unzip "!python_zip!" "!python_dir!" || exit /B call :Unzip "!python_zip!" "!python_dir!" || exit /B
call :Move "!python_dir!\WPy64-!python_version_nodot!" "!python_dir!" || exit /B call :Move "!python_dir!\WPy64-!python_version_nodot!" "!python_dir!" || exit /B
)
call :VerifyFileSHA256 "!python_exe!" "!python_version!" "!python_exe_sha256!" || exit /B
set python_bin_dir=!python_dir!\python-!python_version_dot!.amd64
set python_scripts_bin_dir=!python_bin_dir!\Scripts
) )
call :VerifyFileSHA256 "!python_exe!" "!python_version!" "!python_exe_sha256!" || exit /B
set python_bin_dir=!python_dir!\python-!python_version_dot!.amd64
set python_scripts_bin_dir=!python_bin_dir!\Scripts
REM ---------------------------------------------------------------------------- REM ----------------------------------------------------------------------------
REM RenderDoc REM RenderDoc
REM ---------------------------------------------------------------------------- REM ----------------------------------------------------------------------------
if !install_renderdoc! == 1 ( set renderdoc_sha256=a97a9911850c8a93dc1dee8f94e339cd5933310513dddf0216d27cea3a5f25b1
set renderdoc_sha256=a97a9911850c8a93dc1dee8f94e339cd5933310513dddf0216d27cea3a5f25b1 set renderdoc_exe_sha256=27c28b813f01781573507b0d9b47546d323ae8add2695bbd03b941461868a7a2
set renderdoc_exe_sha256=27c28b813f01781573507b0d9b47546d323ae8add2695bbd03b941461868a7a2 set renderdoc_version=1.18
set renderdoc_version=1.18
set renderdoc_zip=!downloads_dir!\win32_renderdoc-!renderdoc_version!.zip set renderdoc_zip=!downloads_dir!\win32_renderdoc-!renderdoc_version!.zip
set renderdoc_dir=!tools_dir!\renderdoc-x64-!renderdoc_version! set renderdoc_dir=!tools_dir!\renderdoc-x64-!renderdoc_version!
set renderdoc_exe=!renderdoc_dir!\qrenderdoc.exe set renderdoc_exe=!renderdoc_dir!\qrenderdoc.exe
if not exist "!renderdoc_exe!" ( if not exist "!renderdoc_exe!" (
call :DownloadFile "https://renderdoc.org/stable/!renderdoc_version!/RenderDoc_!renderdoc_version!_64.zip" "!renderdoc_zip!" || exit /B call :DownloadFile "https://renderdoc.org/stable/!renderdoc_version!/RenderDoc_!renderdoc_version!_64.zip" "!renderdoc_zip!" || exit /B
call :VerifyZipSHA256 "!renderdoc_zip!" "!renderdoc_sha256!" || exit /B call :VerifyZipSHA256 "!renderdoc_zip!" "!renderdoc_sha256!" || exit /B
call :Unzip "!renderdoc_zip!" "!renderdoc_dir!" || exit /B call :Unzip "!renderdoc_zip!" "!renderdoc_dir!" || exit /B
call :Move "!renderdoc_dir!\RenderDoc_!renderdoc_version!_64" "!renderdoc_dir!" || exit /B call :Move "!renderdoc_dir!\RenderDoc_!renderdoc_version!_64" "!renderdoc_dir!" || exit /B
)
call :VerifyFileSHA256 "!renderdoc_exe!" "!renderdoc_version!" "!renderdoc_exe_sha256!" || exit /B
) )
call :VerifyFileSHA256 "!renderdoc_exe!" "!renderdoc_version!" "!renderdoc_exe_sha256!" || exit /B
REM ---------------------------------------------------------------------------- REM ----------------------------------------------------------------------------
REM Zig REM Zig
REM ---------------------------------------------------------------------------- REM ----------------------------------------------------------------------------
if !install_zig! == 1 ( set zig_sha256=43573db14cd238f7111d6bdf37492d363f11ecd1eba802567a172f277d003926
set zig_sha256=43573db14cd238f7111d6bdf37492d363f11ecd1eba802567a172f277d003926 set zig_exe_sha256=465739a787178ded19efab55916b587f3ead2a9cdff8dcaaf1765fe907797917
set zig_exe_sha256=465739a787178ded19efab55916b587f3ead2a9cdff8dcaaf1765fe907797917 set zig_version=0.8.1
set zig_version=0.8.1
set zig_file=zig-windows-x86_64-!zig_version!.zip set zig_file=zig-windows-x86_64-!zig_version!.zip
set zig_zip=!downloads_dir!\win32_!zig_file! set zig_zip=!downloads_dir!\win32_!zig_file!
set zig_dir=!tools_dir!\zig-windows-x86_64-!zig_version! set zig_dir=!tools_dir!\zig-windows-x86_64-!zig_version!
set zig_exe=!zig_dir!\zig.exe set zig_exe=!zig_dir!\zig.exe
if not exist "!zig_exe!" ( if not exist "!zig_exe!" (
call :DownloadFile "https://ziglang.org/download/!zig_version!/!zig_file!" "!zig_zip!" || exit /B call :DownloadFile "https://ziglang.org/download/!zig_version!/!zig_file!" "!zig_zip!" || exit /B
call :VerifyZipSHA256 "!zig_zip!" "!zig_sha256!" || exit /B call :VerifyZipSHA256 "!zig_zip!" "!zig_sha256!" || exit /B
call :Unzip "!zig_zip!" "!zig_dir!" || exit /B call :Unzip "!zig_zip!" "!zig_dir!" || exit /B
)
call :VerifyFileSHA256 "!zig_exe!" "!zig_version!" "!zig_exe_sha256!" || exit /B
call :MakeBatchShortcutInBinDir "zig" "!zig_exe!"
) )
call :VerifyFileSHA256 "!zig_exe!" "!zig_version!" "!zig_exe_sha256!" || exit /B
call :MakeBatchShortcutInBinDir "zig" "!zig_exe!"
REM ----------------------------------------------------------------------------
REM MSVC
REM ----------------------------------------------------------------------------
set msvc_version=14.31
set msvc_sdk_version=22000
set msvc_dir=!tools_dir!\msvc-v!msvc_version!-win10-sdk-v!msvc_sdk_version!-x64
if not exist "!msvc_dir!" (
call "!python_exe!" !tools_dir!\portable-msvc.py --accept-license --msvc-version !msvc_version! --sdk-version !msvc_sdk_version! || exit /B
call :Move "!tools_dir!\msvc" "!msvc_dir!" || exit /B
)
REM ----------------------------------------------------------------------------
REM Symget
REM ----------------------------------------------------------------------------
set symget_dir=!tools_dir!\symget
if not exist "!symget_dir!" (
call !git_exe! clone https://github.com/mmozeiko/symget.git !symget_dir! || exit /B
)
call !git_exe! -C !symget_dir! pull origin main || exit /B
call !git_exe! -C !symget_dir! checkout 79b026f || exit /B
REM ---------------------------------------------------------------------------- REM ----------------------------------------------------------------------------
REM QoL/Tools REM QoL/Tools
REM ---------------------------------------------------------------------------- REM ----------------------------------------------------------------------------
REM ---------------------------------------------------------------------------- REM ----------------------------------------------------------------------------
REM clink - Bash style tab completion in terminal REM clink - Bash style tab completion in terminal
REM ---------------------------------------------------------------------------- REM ----------------------------------------------------------------------------
if !install_clink! == 1 ( set clink_sha256=31e286313e67a7269ca09ae142e569af7962b03b8f2bc7bd99240416222d8ee8
set clink_sha256=31e286313e67a7269ca09ae142e569af7962b03b8f2bc7bd99240416222d8ee8 set clink_exe_sha256=38b1bb5a8392ac8d7f98d3dcc0a41dc7fc31344800d4facd83e10d9175daf9d8
set clink_exe_sha256=38b1bb5a8392ac8d7f98d3dcc0a41dc7fc31344800d4facd83e10d9175daf9d8 set clink_version=1.3.13
set clink_version=1.3.13 set clink_git_hash=24b02e
set clink_git_hash=24b02e
set clink_zip=!downloads_dir!\win32_clink_!clink_version!.zip set clink_zip=!downloads_dir!\win32_clink_!clink_version!.zip
set clink_dir=!tools_dir!\clink-!clink_version! set clink_dir=!tools_dir!\clink-!clink_version!
set clink_exe=!clink_dir!\clink_x64.exe set clink_exe=!clink_dir!\clink_x64.exe
set clink_bat=!clink_dir!\clink.bat set clink_bat=!clink_dir!\clink.bat
if not exist "!clink_exe!" ( if not exist "!clink_exe!" (
call :DownloadFile "https://github.com/chrisant996/clink/releases/download/v!clink_version!/clink.!clink_version!.!clink_git_hash!.zip" "!clink_zip!" || exit /B call :DownloadFile "https://github.com/chrisant996/clink/releases/download/v!clink_version!/clink.!clink_version!.!clink_git_hash!.zip" "!clink_zip!" || exit /B
call :VerifyZipSHA256 "!clink_zip!" "!clink_sha256!" || exit /B call :VerifyZipSHA256 "!clink_zip!" "!clink_sha256!" || exit /B
call :Unzip "!clink_zip!" "!clink_dir!" || exit /B call :Unzip "!clink_zip!" "!clink_dir!" || exit /B
call :Move "!clink_dir!\clink_!clink_version!" "!clink_dir!" || exit /B call :Move "!clink_dir!\clink_!clink_version!" "!clink_dir!" || exit /B
call :CopyAndAlwaysOverwriteFile "!clink_dir!\_default_inputrc" "!clink_dir!\default_inputrc" || exit /B call :CopyAndAlwaysOverwriteFile "!clink_dir!\_default_inputrc" "!clink_dir!\default_inputrc" || exit /B
call :CopyAndAlwaysOverwriteFile "!clink_dir!\_default_settings" "!clink_dir!\default_settings" || exit /B call :CopyAndAlwaysOverwriteFile "!clink_dir!\_default_settings" "!clink_dir!\default_settings" || exit /B
)
call :VerifyFileSHA256 "!clink_exe!" "!clink_version!" "!clink_exe_sha256!" || exit /B
call :MakeBatchShortcutInBinDir "clink" "!clink_bat!"
if !install_git! == 1 (
set clink_completions_dir=!tools_dir!\clink-completions
if not exist "!clink_completions_dir!" (
call !git_exe! clone https://github.com/vladimir-kotikov/clink-completions !clink_completions_dir! || exit /B
)
call !git_exe! -C !clink_completions_dir! pull origin master || exit /B
call !git_exe! -C !clink_completions_dir! checkout 9ab9342 || exit /B
)
) )
call :VerifyFileSHA256 "!clink_exe!" "!clink_version!" "!clink_exe_sha256!" || exit /B
call :MakeBatchShortcutInBinDir "clink" "!clink_bat!"
REM Clink Completion Addon
set clink_completions_dir=!tools_dir!\clink-completions
if not exist "!clink_completions_dir!" (
call !git_exe! clone https://github.com/vladimir-kotikov/clink-completions !clink_completions_dir! || exit /B
)
call !git_exe! -C !clink_completions_dir! pull origin master || exit /B
call !git_exe! -C !clink_completions_dir! checkout 9ab9342 || exit /B
REM ---------------------------------------------------------------------------- REM ----------------------------------------------------------------------------
REM Dependencies (Walker) - For DLL dependency management REM Dependencies (Walker) - For DLL dependency management
REM ---------------------------------------------------------------------------- REM ----------------------------------------------------------------------------
if !install_dependency_walker! == 1 ( set dependencies_sha256=44df956dbe267e0a705224c3b85d515fee2adc87509861e24fb6c6b0ea1b86d6
set dependencies_sha256=44df956dbe267e0a705224c3b85d515fee2adc87509861e24fb6c6b0ea1b86d6 set dependencies_exe_sha256=f9c9d78284d03b0457061cfb33751071c8c1ceeb26bc9b75ae9b7e0465e99858
set dependencies_exe_sha256=f9c9d78284d03b0457061cfb33751071c8c1ceeb26bc9b75ae9b7e0465e99858 set dependencies_version=v1.10
set dependencies_version=v1.10
set dependencies_zip=!downloads_dir!\win32_dependencies_!dependencies_version!.zip set dependencies_zip=!downloads_dir!\win32_dependencies_!dependencies_version!.zip
set dependencies_dir=!tools_dir!\dependencies-!dependencies_version! set dependencies_dir=!tools_dir!\dependencies-!dependencies_version!
set dependencies_exe=!dependencies_dir!\DependenciesGui.exe set dependencies_exe=!dependencies_dir!\DependenciesGui.exe
if not exist "!dependencies_exe!" ( if not exist "!dependencies_exe!" (
call :DownloadFile "https://github.com/lucasg/Dependencies/releases/download/!dependencies_version!/Dependencies_x64_Release.zip" "!dependencies_zip!" || exit /B call :DownloadFile "https://github.com/lucasg/Dependencies/releases/download/!dependencies_version!/Dependencies_x64_Release.zip" "!dependencies_zip!" || exit /B
call :VerifyZipSHA256 "!dependencies_zip!" "!dependencies_sha256!" || exit /B call :VerifyZipSHA256 "!dependencies_zip!" "!dependencies_sha256!" || exit /B
call :Unzip "!dependencies_zip!" "!dependencies_dir!" || exit /B call :Unzip "!dependencies_zip!" "!dependencies_dir!" || exit /B
)
call :VerifyFileSHA256 "!dependencies_exe!" "!dependencies_version!" "!dependencies_exe_sha256!" || exit /B
) )
call :VerifyFileSHA256 "!dependencies_exe!" "!dependencies_version!" "!dependencies_exe_sha256!" || exit /B
REM ---------------------------------------------------------------------------- REM ----------------------------------------------------------------------------
REM everything (void tools search program) REM everything (void tools search program)
REM ---------------------------------------------------------------------------- REM ----------------------------------------------------------------------------
if !install_everything_void_tools! == 1 ( set everything_sha256=f61b601acba59d61fb0631a654e48a564db34e279b6f2cc45e20a42ce9d9c466
set everything_sha256=f61b601acba59d61fb0631a654e48a564db34e279b6f2cc45e20a42ce9d9c466 set everything_exe_sha256=48a17c3c22476f642c2b1ab2da8dfd789e39882997d7a8e266104f7404a0ded9
set everything_exe_sha256=48a17c3c22476f642c2b1ab2da8dfd789e39882997d7a8e266104f7404a0ded9 set everything_version=1.4.1.1009
set everything_version=1.4.1.1009
set everything_zip=!downloads_dir!\win32_everything_v!everything_version!.7z set everything_zip=!downloads_dir!\win32_everything_v!everything_version!.7z
set everything_dir=!tools_dir!\everything-!everything_version! set everything_dir=!tools_dir!\everything-!everything_version!
set everything_exe=!everything_dir!\everything.exe set everything_exe=!everything_dir!\everything.exe
if not exist "!everything_exe!" ( if not exist "!everything_exe!" (
call :DownloadFile "https://www.voidtools.com/Everything-!everything_version!.x64.zip" "!everything_zip!" || exit /B call :DownloadFile "https://www.voidtools.com/Everything-!everything_version!.x64.zip" "!everything_zip!" || exit /B
call :VerifyZipSHA256 "!everything_zip!" "!everything_sha256!" || exit /B call :VerifyZipSHA256 "!everything_zip!" "!everything_sha256!" || exit /B
call :Unzip "!everything_zip!" "!everything_dir!" || exit /B call :Unzip "!everything_zip!" "!everything_dir!" || exit /B
)
call :VerifyFileSHA256 "!everything_exe!" "!everything_version!" "!everything_exe_sha256!" || exit /B
) )
call :VerifyFileSHA256 "!everything_exe!" "!everything_version!" "!everything_exe_sha256!" || exit /B
REM ---------------------------------------------------------------------------- REM ----------------------------------------------------------------------------
REM fzf REM fzf
REM ---------------------------------------------------------------------------- REM ----------------------------------------------------------------------------
if !install_fzf! == 1 ( set fzf_sha256=f0797ceee089017108c80b09086c71b8eec43d4af11ce939b78b1d5cfd202540
set fzf_sha256=f0797ceee089017108c80b09086c71b8eec43d4af11ce939b78b1d5cfd202540 set fzf_exe_sha256=5176c4c90957aa7e3d12f91b8ba55acac7524a83998517119ee19b61f4534140
set fzf_exe_sha256=5176c4c90957aa7e3d12f91b8ba55acac7524a83998517119ee19b61f4534140 set fzf_version=0.29.0
set fzf_version=0.29.0
set fzf_zip=!downloads_dir!\win32_fzf_v!fzf_version!.zip set fzf_zip=!downloads_dir!\win32_fzf_v!fzf_version!.zip
set fzf_dir=!bin_dir! set fzf_dir=!bin_dir!
set fzf_exe=!fzf_dir!\fzf.exe set fzf_exe=!fzf_dir!\fzf.exe
if not exist "!fzf_exe!-!fzf_version!.sha256.txt" ( if not exist "!fzf_exe!-!fzf_version!.sha256.txt" (
call :DownloadFile "https://github.com/junegunn/fzf/releases/download/!fzf_version!/fzf-!fzf_version!-windows_amd64.zip" "!fzf_zip!" || exit /B call :DownloadFile "https://github.com/junegunn/fzf/releases/download/!fzf_version!/fzf-!fzf_version!-windows_amd64.zip" "!fzf_zip!" || exit /B
call :VerifyZipSHA256 "!fzf_zip!" "!fzf_sha256!" || exit /B call :VerifyZipSHA256 "!fzf_zip!" "!fzf_sha256!" || exit /B
call :UnzipAndAlwaysOverwrite "!fzf_zip!" "!fzf_dir!" || exit /B call :UnzipAndAlwaysOverwrite "!fzf_zip!" "!fzf_dir!" || exit /B
)
call :VerifyFileSHA256 "!fzf_exe!" "!fzf_version!" "!fzf_exe_sha256!" || exit /B
) )
call :VerifyFileSHA256 "!fzf_exe!" "!fzf_version!" "!fzf_exe_sha256!" || exit /B
REM ---------------------------------------------------------------------------- REM ----------------------------------------------------------------------------
REM GVim, Vim Plug, Vim Config REM GVim, Vim Plug, Vim Config
REM ---------------------------------------------------------------------------- REM ----------------------------------------------------------------------------
if !install_gvim! == 1 ( set gvim_zip=!downloads_dir!\win32_gvim_x64.7z
set gvim_zip=!downloads_dir!\win32_gvim_x64.7z set gvim_dir=!tools_dir!\GVim
set gvim_dir=!tools_dir!\GVim if not exist "!gvim_dir!\gvim.exe" (
if not exist "!gvim_dir!\gvim.exe" (
call :DownloadFile https://tuxproject.de/projects/vim/complete-x64.7z !gvim_zip! || exit /B call :DownloadFile https://tuxproject.de/projects/vim/complete-x64.7z !gvim_zip! || exit /B
call :Unzip "!gvim_zip!" "!gvim_dir!" || exit /B call :Unzip "!gvim_zip!" "!gvim_dir!" || exit /B
)
call :CopyAndAlwaysOverwriteFile "!install_dir!\_vimrc" !home_dir!
REM DLL that hooks into GVIM and provides fullscreen with F11
set gvim_fullscreen_dll_sha256=1c83747b67ed73c05d44c1af8222a860bc5a48b56bf54cd6e21465a2deb78456
set gvim_fullscreen_dll=!gvim_dir!\gvim_fullscreen.dll
call :CopyAndAlwaysOverwriteFile "!install_dir!\win32_gvim_fullscreen.dll" "!gvim_fullscreen_dll!" || exit /B
call :VerifyFileSHA256 "!gvim_fullscreen_dll!" "none" "!gvim_fullscreen_dll_sha256!" || exit /B
set vim_plug_dir=!vim_dir!\autoload
set vim_plug=!vim_plug_dir!\plug.vim
if not exist "!vim_plug_dir!" mkdir "!vim_plug_dir!"
call :DownloadFile "https://raw.githubusercontent.com/junegunn/vim-plug/master/plug.vim" "!vim_plug!" || exit /B
) )
call :CopyAndAlwaysOverwriteFile "!install_dir!\_vimrc" !home_dir!
REM DLL that hooks into GVIM and provides fullscreen with F11
set gvim_fullscreen_dll_sha256=1c83747b67ed73c05d44c1af8222a860bc5a48b56bf54cd6e21465a2deb78456
set gvim_fullscreen_dll=!gvim_dir!\gvim_fullscreen.dll
call :CopyAndAlwaysOverwriteFile "!install_dir!\win32_gvim_fullscreen.dll" "!gvim_fullscreen_dll!" || exit /B
call :VerifyFileSHA256 "!gvim_fullscreen_dll!" "none" "!gvim_fullscreen_dll_sha256!" || exit /B
set vim_plug_dir=!vim_dir!\autoload
set vim_plug=!vim_plug_dir!\plug.vim
if not exist "!vim_plug_dir!" mkdir "!vim_plug_dir!"
call :DownloadFile "https://raw.githubusercontent.com/junegunn/vim-plug/master/plug.vim" "!vim_plug!" || exit /B
REM ---------------------------------------------------------------------------- REM ----------------------------------------------------------------------------
REM ImHex REM ImHex
REM ---------------------------------------------------------------------------- REM ----------------------------------------------------------------------------
if !install_imhex! == 1 ( set imhex_sha256=080f537d3ea58c002cc2112adbec1352144710b43764de9a1dc04f129d3a3343
set imhex_sha256=080f537d3ea58c002cc2112adbec1352144710b43764de9a1dc04f129d3a3343 set imhex_exe_sha256=6a4b0e70bf7c78af074af0de2346164d9f5aec28ea224f9ee903412e1c774d95
set imhex_exe_sha256=6a4b0e70bf7c78af074af0de2346164d9f5aec28ea224f9ee903412e1c774d95 set imhex_version=1.17.0
set imhex_version=1.17.0
set imhex_zip=!downloads_dir!\win32_imhex_v!imhex_version!.zip set imhex_zip=!downloads_dir!\win32_imhex_v!imhex_version!.zip
set imhex_dir=!tools_dir!\imhex-x64-x!imhex_version! set imhex_dir=!tools_dir!\imhex-x64-x!imhex_version!
set imhex_exe=!imhex_dir!\imhex.exe set imhex_exe=!imhex_dir!\imhex.exe
if not exist "!imhex_exe!-!imhex_version!.sha256.txt" ( if not exist "!imhex_exe!-!imhex_version!.sha256.txt" (
call :DownloadFile "https://github.com/WerWolv/ImHex/releases/download/v!imhex_version!/Windows.Portable.ZIP.zip" "!imhex_zip!" || exit /B call :DownloadFile "https://github.com/WerWolv/ImHex/releases/download/v!imhex_version!/Windows.Portable.ZIP.zip" "!imhex_zip!" || exit /B
call :VerifyZipSHA256 "!imhex_zip!" "!imhex_sha256!" || exit /B call :VerifyZipSHA256 "!imhex_zip!" "!imhex_sha256!" || exit /B
call :UnzipAndAlwaysOverwrite "!imhex_zip!" "!imhex_dir!" || exit /B call :UnzipAndAlwaysOverwrite "!imhex_zip!" "!imhex_dir!" || exit /B
)
call :VerifyFileSHA256 "!imhex_exe!" "!imhex_version!" "!imhex_exe_sha256!" || exit /B
) )
call :VerifyFileSHA256 "!imhex_exe!" "!imhex_version!" "!imhex_exe_sha256!" || exit /B
REM ---------------------------------------------------------------------------- REM ----------------------------------------------------------------------------
REM Joplin REM Joplin
REM ---------------------------------------------------------------------------- REM ----------------------------------------------------------------------------
if !install_joplin! == 1 ( set joplin_sha256=2dba85ba6887d9318b10aafda00531f804f311ef9d1c899eefbcba116bf50ed2
set joplin_sha256=2dba85ba6887d9318b10aafda00531f804f311ef9d1c899eefbcba116bf50ed2 set joplin_version=2.6.10
set joplin_version=2.6.10
set joplin_dir=!tools_dir!\joplin-x64-!joplin_version! set joplin_dir=!tools_dir!\joplin-x64-!joplin_version!
set joplin_exe=!joplin_dir!\JoplinPortable.exe set joplin_exe=!joplin_dir!\JoplinPortable.exe
if not exist "!joplin_exe!" ( if not exist "!joplin_exe!" (
if not exist "!joplin_dir!" mkdir "!joplin_dir!" if not exist "!joplin_dir!" mkdir "!joplin_dir!"
call :DownloadFile "https://github.com/laurent22/joplin/releases/download/v!joplin_version!/JoplinPortable.exe" "!joplin_exe!" || exit /B call :DownloadFile "https://github.com/laurent22/joplin/releases/download/v!joplin_version!/JoplinPortable.exe" "!joplin_exe!" || exit /B
)
call :VerifyFileSHA256 "!joplin_exe!" "!joplin_version!" "!joplin_sha256!" || exit /B
) )
call :VerifyFileSHA256 "!joplin_exe!" "!joplin_version!" "!joplin_sha256!" || exit /B
REM ---------------------------------------------------------------------------- REM ----------------------------------------------------------------------------
REM Keypirinha REM Keypirinha
REM ---------------------------------------------------------------------------- REM ----------------------------------------------------------------------------
if !install_keypirinha! == 1 ( set keypirinha_sha256=d109a16e6a5cf311abf6d06bbe5b1be3b9ba323b79c32a168628189e10f102a5
set keypirinha_sha256=d109a16e6a5cf311abf6d06bbe5b1be3b9ba323b79c32a168628189e10f102a5 set keypirinha_exe_sha256=2d3adb36a04e9fdf94636c9ac5d4c2b754accbfaecd81f4ee7189c3c0edc8af1
set keypirinha_exe_sha256=2d3adb36a04e9fdf94636c9ac5d4c2b754accbfaecd81f4ee7189c3c0edc8af1 set keypirinha_version=2.26
set keypirinha_version=2.26
set keypirinha_zip=!downloads_dir!\win32_keypirinha-x64-!keypirinha_version!.7z set keypirinha_zip=!downloads_dir!\win32_keypirinha-x64-!keypirinha_version!.7z
set keypirinha_dir=!tools_dir!\keypirinha-x64-!keypirinha_version! set keypirinha_dir=!tools_dir!\keypirinha-x64-!keypirinha_version!
set keypirinha_exe=!keypirinha_dir!\keypirinha.exe set keypirinha_exe=!keypirinha_dir!\keypirinha.exe
if not exist "!keypirinha_exe!" ( if not exist "!keypirinha_exe!" (
call :DownloadFile "https://github.com/Keypirinha/Keypirinha/releases/download/v!keypirinha_version!/keypirinha-!keypirinha_version!-x64-portable.7z" "!keypirinha_zip!" || exit /B call :DownloadFile "https://github.com/Keypirinha/Keypirinha/releases/download/v!keypirinha_version!/keypirinha-!keypirinha_version!-x64-portable.7z" "!keypirinha_zip!" || exit /B
call :VerifyZipSHA256 "!keypirinha_zip!" "!keypirinha_sha256!" || exit /B call :VerifyZipSHA256 "!keypirinha_zip!" "!keypirinha_sha256!" || exit /B
call :Unzip "!keypirinha_zip!" "!keypirinha_dir!" || exit /B call :Unzip "!keypirinha_zip!" "!keypirinha_dir!" || exit /B
call :Move "!keypirinha_dir!\keypirinha" "!keypirinha_dir!" || exit /B call :Move "!keypirinha_dir!\keypirinha" "!keypirinha_dir!" || exit /B
)
call :VerifyFileSHA256 "!keypirinha_exe!" "!keypirinha_version!" "!keypirinha_exe_sha256!" || exit /B
) )
call :VerifyFileSHA256 "!keypirinha_exe!" "!keypirinha_version!" "!keypirinha_exe_sha256!" || exit /B
REM ---------------------------------------------------------------------------- REM ----------------------------------------------------------------------------
REM Misc Tools REM Misc Tools
REM ---------------------------------------------------------------------------- REM ----------------------------------------------------------------------------
@ -524,105 +510,95 @@ call :CopyAndAlwaysOverwriteFile "!install_dir!\clang_format_style_file" "!home_
REM ------------------------------------------------------------------------ REM ------------------------------------------------------------------------
REM MobaXTerm REM MobaXTerm
REM ------------------------------------------------------------------------ REM ------------------------------------------------------------------------
if !install_mobaxterm! == 1 ( set mobaxterm_sha256=91f80537f12c2ad34a5eba99a285c149781c6d35a144a965ce3aea8a9bc6868c
set mobaxterm_sha256=91f80537f12c2ad34a5eba99a285c149781c6d35a144a965ce3aea8a9bc6868c set mobaxterm_exe_sha256=1053c81b44018d6e6519a9c80d7413f7bb36e9f6e43b3da619b2229aa362a522
set mobaxterm_exe_sha256=1053c81b44018d6e6519a9c80d7413f7bb36e9f6e43b3da619b2229aa362a522 set mobaxterm_version=21.2
set mobaxterm_version=21.2
set mobaxterm_zip=!downloads_dir!\win32_mobaxterm-!mobaxterm_version!.zip set mobaxterm_zip=!downloads_dir!\win32_mobaxterm-!mobaxterm_version!.zip
set mobaxterm_dir=!tools_dir!\mobaxterm-!mobaxterm_version! set mobaxterm_dir=!tools_dir!\mobaxterm-!mobaxterm_version!
set mobaxterm_exe=!mobaxterm_dir!\MobaXterm_Personal_21.2.exe set mobaxterm_exe=!mobaxterm_dir!\MobaXterm_Personal_21.2.exe
if not exist "!mobaxterm_exe!" ( if not exist "!mobaxterm_exe!" (
call :DownloadFile "https://download.mobatek.net/2122021051924233/MobaXterm_Portable_v!mobaxterm_version!.zip" !mobaxterm_zip! || exit /B call :DownloadFile "https://download.mobatek.net/2122021051924233/MobaXterm_Portable_v!mobaxterm_version!.zip" !mobaxterm_zip! || exit /B
call :VerifyZipSHA256 !mobaxterm_zip! !mobaxterm_sha256! || exit /B call :VerifyZipSHA256 !mobaxterm_zip! !mobaxterm_sha256! || exit /B
call :Unzip !mobaxterm_zip! !mobaxterm_dir! || exit /B call :Unzip !mobaxterm_zip! !mobaxterm_dir! || exit /B
)
call :VerifyFileSHA256 "!mobaxterm_exe!" "!mobaxterm_version!" "!mobaxterm_exe_sha256!" || exit /B
) )
call :VerifyFileSHA256 "!mobaxterm_exe!" "!mobaxterm_version!" "!mobaxterm_exe_sha256!" || exit /B
REM ---------------------------------------------------------------------------- REM ----------------------------------------------------------------------------
REM O&O ShutUp10 (Privacy Tool for Windows) REM O&O ShutUp10 (Privacy Tool for Windows)
REM ---------------------------------------------------------------------------- REM ----------------------------------------------------------------------------
if !install_ooshutup10! == 1 ( REM We don't do SHA256 here since we don't get a versioned URL, this can
REM change at a whim and it'd be painful to have to reupdate the script
REM everytime.
REM We don't do SHA256 here since we don't get a versioned URL, this can set oo_shutup_10_dir=!tools_dir!\oo_shutup_10
REM change at a whim and it'd be painful to have to reupdate the script set oo_shutup_10_file=!oo_shutup_10_dir!\oo_shutup_10.exe
REM everytime.
set oo_shutup_10_dir=!tools_dir!\oo_shutup_10 if not exist "!oo_shutup_10_file!" (
set oo_shutup_10_file=!oo_shutup_10_dir!\oo_shutup_10.exe
if not exist "!oo_shutup_10_file!" (
if not exist "!oo_shutup_10_dir!" mkdir "!oo_shutup_10_dir!" if not exist "!oo_shutup_10_dir!" mkdir "!oo_shutup_10_dir!"
call :DownloadFile "https://dl5.oo-software.com/files/ooshutup10/OOSU10.exe" "!oo_shutup_10_file!" || exit /B call :DownloadFile "https://dl5.oo-software.com/files/ooshutup10/OOSU10.exe" "!oo_shutup_10_file!" || exit /B
)
) )
REM ---------------------------------------------------------------------------- REM ----------------------------------------------------------------------------
REM ProcessHacker REM ProcessHacker
REM ---------------------------------------------------------------------------- REM ----------------------------------------------------------------------------
if !install_process_hacker! == 1 ( set process_hacker_sha256=e8836365abab7478d8e4c2d3fb3bb1fce82048cd4da54bab41cacbae1f45b1ff
set process_hacker_sha256=e8836365abab7478d8e4c2d3fb3bb1fce82048cd4da54bab41cacbae1f45b1ff set process_hacker_exe_sha256=46367bfcf4b150da573a74d91aa2f7caf7a0789741bc65878a028e91ffbf5e42
set process_hacker_exe_sha256=46367bfcf4b150da573a74d91aa2f7caf7a0789741bc65878a028e91ffbf5e42 set process_hacker_version=3.0.4212
set process_hacker_version=3.0.4212
set process_hacker_zip=!downloads_dir!\win32_process_hacker-!process_hacker_version!.zip set process_hacker_zip=!downloads_dir!\win32_process_hacker-!process_hacker_version!.zip
set process_hacker_dir=!tools_dir!\process_hacker-!process_hacker_version! set process_hacker_dir=!tools_dir!\process_hacker-!process_hacker_version!
set process_hacker_exe=!process_hacker_dir!\64bit\ProcessHacker.exe set process_hacker_exe=!process_hacker_dir!\64bit\ProcessHacker.exe
if not exist "!process_hacker_exe!" ( if not exist "!process_hacker_exe!" (
call :DownloadFile "https://ci.appveyor.com/api/buildjobs/8say005q9xy48cc3/artifacts/processhacker-!process_hacker_version!-bin.zip" "!process_hacker_zip!" || exit /B call :DownloadFile "https://ci.appveyor.com/api/buildjobs/8say005q9xy48cc3/artifacts/processhacker-!process_hacker_version!-bin.zip" "!process_hacker_zip!" || exit /B
call :VerifyZipSHA256 "!process_hacker_zip!" "!process_hacker_sha256!" || exit /B call :VerifyZipSHA256 "!process_hacker_zip!" "!process_hacker_sha256!" || exit /B
call :Unzip "!process_hacker_zip!" "!process_hacker_dir!" || exit /B call :Unzip "!process_hacker_zip!" "!process_hacker_dir!" || exit /B
)
call :VerifyFileSHA256 "!process_hacker_exe!" "!process_hacker_version!" "!process_hacker_exe_sha256!" || exit /B
) )
call :VerifyFileSHA256 "!process_hacker_exe!" "!process_hacker_version!" "!process_hacker_exe_sha256!" || exit /B
REM ---------------------------------------------------------------------------- REM ----------------------------------------------------------------------------
REM ripgrep REM ripgrep
REM ---------------------------------------------------------------------------- REM ----------------------------------------------------------------------------
if !install_ripgrep! == 1 ( set rg_sha256=a47ace6f654c5ffa236792fc3ee3fefd9c7e88e026928b44da801acb72124aa8
set rg_sha256=a47ace6f654c5ffa236792fc3ee3fefd9c7e88e026928b44da801acb72124aa8 set rg_exe_sha256=ab5595a4f7a6b918cece0e7e22ebc883ead6163948571419a1dd5cd3c7f37972
set rg_exe_sha256=ab5595a4f7a6b918cece0e7e22ebc883ead6163948571419a1dd5cd3c7f37972 set rg_version=13.0.0
set rg_version=13.0.0
set rg_zip=!downloads_dir!\win32_rg_v!rg_version!.zip set rg_zip=!downloads_dir!\win32_rg_v!rg_version!.zip
set rg_dir=!tools_dir!\ripgrep-!rg_version! set rg_dir=!tools_dir!\ripgrep-!rg_version!
set rg_exe=!rg_dir!\rg.exe set rg_exe=!rg_dir!\rg.exe
if not exist "!rg_exe!" ( if not exist "!rg_exe!" (
call :DownloadFile "https://github.com/BurntSushi/ripgrep/releases/download/!rg_version!/ripgrep-!rg_version!-x86_64-pc-windows-msvc.zip" "!rg_zip!" || exit /B call :DownloadFile "https://github.com/BurntSushi/ripgrep/releases/download/!rg_version!/ripgrep-!rg_version!-x86_64-pc-windows-msvc.zip" "!rg_zip!" || exit /B
call :VerifyZipSHA256 "!rg_zip!" "!rg_sha256!" || exit /B call :VerifyZipSHA256 "!rg_zip!" "!rg_sha256!" || exit /B
call :Unzip "!rg_zip!" "!rg_dir!" || exit /B call :Unzip "!rg_zip!" "!rg_dir!" || exit /B
call :Move "!rg_dir!\ripgrep-!rg_version!-x86_64-pc-windows-msvc" "!rg_dir!" || exit /B call :Move "!rg_dir!\ripgrep-!rg_version!-x86_64-pc-windows-msvc" "!rg_dir!" || exit /B
)
call :VerifyFileSHA256 "!rg_exe!" "!rg_version!" "!rg_exe_sha256!" || exit /B
call :MakeBatchShortcutInBinDir "rg" "!rg_exe!"
) )
call :VerifyFileSHA256 "!rg_exe!" "!rg_version!" "!rg_exe_sha256!" || exit /B
call :MakeBatchShortcutInBinDir "rg" "!rg_exe!"
REM ---------------------------------------------------------------------------- REM ----------------------------------------------------------------------------
REM Ethereum REM Ethereum
REM ---------------------------------------------------------------------------- REM ----------------------------------------------------------------------------
REM ---------------------------------------------------------------------------- REM ----------------------------------------------------------------------------
REM geth REM geth
REM ---------------------------------------------------------------------------- REM ----------------------------------------------------------------------------
if !install_geth! == 1 ( set geth_md5=a975ba6591577b6f5b19f4fd8757fd03
set geth_md5=a975ba6591577b6f5b19f4fd8757fd03 set geth_exe_sha256=7d9fd1566f2fd07c741a64aad2865b25f8cd82388e15bed2d68e92105b1e0fd3
set geth_exe_sha256=7d9fd1566f2fd07c741a64aad2865b25f8cd82388e15bed2d68e92105b1e0fd3 set geth_version=1.10.8-26675454
set geth_version=1.10.8-26675454
set geth_zip=!downloads_dir!\win32_geth-amd64-v!geth_version!.zip set geth_zip=!downloads_dir!\win32_geth-amd64-v!geth_version!.zip
set geth_dir=!tools_dir!\geth-windows-amd64-!geth_version! set geth_dir=!tools_dir!\geth-windows-amd64-!geth_version!
set geth_exe=!geth_dir!\geth.exe set geth_exe=!geth_dir!\geth.exe
set geth_gpg_key=!downloads_dir!\..\geth_windows_builder_gpg_key.asc set geth_gpg_key=!downloads_dir!\..\geth_windows_builder_gpg_key.asc
set geth_gpg_sig=!geth_zip!.asc set geth_gpg_sig=!geth_zip!.asc
if not exist "!geth_exe!" ( if not exist "!geth_exe!" (
call :DownloadFile "https://gethstore.blob.core.windows.net/builds/geth-windows-amd64-!geth_version!.zip" "!geth_zip!" || exit /B call :DownloadFile "https://gethstore.blob.core.windows.net/builds/geth-windows-amd64-!geth_version!.zip" "!geth_zip!" || exit /B
call :DownloadFile "https://gethstore.blob.core.windows.net/builds/geth-windows-amd64-!geth_version!.zip.asc" "!geth_gpg_sig! || exit /B call :DownloadFile "https://gethstore.blob.core.windows.net/builds/geth-windows-amd64-!geth_version!.zip.asc" "!geth_gpg_sig! || exit /B
call :VerifyFileMD5 "!geth_zip!" "!geth_version!" "!geth_md5!" || exit /B call :VerifyFileMD5 "!geth_zip!" "!geth_version!" "!geth_md5!" || exit /B
@ -630,57 +606,51 @@ if !install_geth! == 1 (
gpg --import "!geth_gpg_key!" || exit /B gpg --import "!geth_gpg_key!" || exit /B
gpg --verify "!geth_gpg_sig!" "!geth_zip!" || exit /B gpg --verify "!geth_gpg_sig!" "!geth_zip!" || exit /B
call :Unzip "!geth_zip!" "!geth_dir!" || exit /B call :Unzip "!geth_zip!" "!geth_dir!" || exit /B
)
call :VerifyFileSHA256 "!geth_exe!" "!geth_version!" "!geth_exe_sha256!" || exit /B
call :MakeBatchShortcutInBinDir "geth" "!geth_exe!"
) )
call :VerifyFileSHA256 "!geth_exe!" "!geth_version!" "!geth_exe_sha256!" || exit /B
call :MakeBatchShortcutInBinDir "geth" "!geth_exe!"
REM ---------------------------------------------------------------------------- REM ----------------------------------------------------------------------------
REM remix_ide REM remix_ide
REM ---------------------------------------------------------------------------- REM ----------------------------------------------------------------------------
if !install_remix_ide! == 1 ( set remix_ide_sha256=19a56cb79459e612d8cbdd6b6729d06c7080d983537d2494a15fd25ea67b2499
set remix_ide_sha256=19a56cb79459e612d8cbdd6b6729d06c7080d983537d2494a15fd25ea67b2499 set remix_ide_exe_sha256=960bc454e37a718b86018b596d14ed977d1a8e1a5bc57b5afd573fc5e9b84a47
set remix_ide_exe_sha256=960bc454e37a718b86018b596d14ed977d1a8e1a5bc57b5afd573fc5e9b84a47 set remix_ide_version=1.3.1
set remix_ide_version=1.3.1
set remix_ide_zip=!downloads_dir!\win32_remix-ide-amd64-v!remix_ide_version!.zip set remix_ide_zip=!downloads_dir!\win32_remix-ide-amd64-v!remix_ide_version!.zip
set remix_ide_dir=!tools_dir!\remix-ide-!remix_ide_version! set remix_ide_dir=!tools_dir!\remix-ide-!remix_ide_version!
set remix_ide_exe=!remix_ide_dir!\Remix IDE.exe set remix_ide_exe=!remix_ide_dir!\Remix IDE.exe
if not exist "!remix_ide_exe!" ( if not exist "!remix_ide_exe!" (
call :DownloadFile "https://github.com/ethereum/remix-desktop/releases/download/v!remix_ide_version!/Remix-IDE-!remix_ide_version!-win.zip" "!remix_ide_zip!" || exit /B call :DownloadFile "https://github.com/ethereum/remix-desktop/releases/download/v!remix_ide_version!/Remix-IDE-!remix_ide_version!-win.zip" "!remix_ide_zip!" || exit /B
call :VerifyZipSHA256 "!remix_ide_zip!" "!remix_ide_sha256!" || exit /B call :VerifyZipSHA256 "!remix_ide_zip!" "!remix_ide_sha256!" || exit /B
call :Unzip "!remix_ide_zip!" "!remix_ide_dir!" || exit /B call :Unzip "!remix_ide_zip!" "!remix_ide_dir!" || exit /B
)
call :VerifyFileSHA256 "!remix_ide_exe!" "!remix_ide_version!" "!remix_ide_exe_sha256!" || exit /B
) )
call :VerifyFileSHA256 "!remix_ide_exe!" "!remix_ide_version!" "!remix_ide_exe_sha256!" || exit /B
REM ---------------------------------------------------------------------------- REM ----------------------------------------------------------------------------
REM solidity REM solidity
REM ---------------------------------------------------------------------------- REM ----------------------------------------------------------------------------
if !install_solidity! == 1 ( set solidity_exe_sha256=82db83111c6e2c892179486cb7050d85f1517bf851027607eb7f4e589e714bc5
set solidity_exe_sha256=82db83111c6e2c892179486cb7050d85f1517bf851027607eb7f4e589e714bc5 set solidity_version=0.8.7+commit.e28d00a7
set solidity_version=0.8.7+commit.e28d00a7
set solidity_dir=!tools_dir!\solidity-windows-amd64-!solidity_version! set solidity_dir=!tools_dir!\solidity-windows-amd64-!solidity_version!
set solidity_exe=!solidity_dir!\solc.exe set solidity_exe=!solidity_dir!\solc.exe
if not exist "!solidity_exe!" ( if not exist "!solidity_exe!" (
if not exist "!solidity_dir!" mkdir "!solidity_dir!" if not exist "!solidity_dir!" mkdir "!solidity_dir!"
call :DownloadFile "https://binaries.soliditylang.org/windows-amd64/solc-windows-amd64-v!solidity_version!.exe" "!solidity_exe!" || exit /B call :DownloadFile "https://binaries.soliditylang.org/windows-amd64/solc-windows-amd64-v!solidity_version!.exe" "!solidity_exe!" || exit /B
)
call :VerifyFileSHA256 "!solidity_exe!" "!solidity_version!" "!solidity_exe_sha256!" || exit /B
call :MakeBatchShortcutInBinDir "solc" "!solidity_exe!"
) )
call :VerifyFileSHA256 "!solidity_exe!" "!solidity_version!" "!solidity_exe_sha256!" || exit /B
call :MakeBatchShortcutInBinDir "solc" "!solidity_exe!"
REM ---------------------------------------------------------------------------- REM ----------------------------------------------------------------------------
REM Super Terminal REM Super Terminal
REM ---------------------------------------------------------------------------- REM ----------------------------------------------------------------------------
set terminal_script=!root_dir!\win32_terminal.bat set terminal_script=!root_dir!\win32_terminal.bat
set msvc_script=!tools_dir!\MSVC-2019-v16.9.2-VC-v14.28.29910-Win10-SDK-v10.0.19041.0-x64\msvc_env_x64.bat
echo @echo off> "!terminal_script!" echo @echo off> "!terminal_script!"
@ -692,54 +662,49 @@ echo set LOCALAPPDATA=%%~dp0!home_dir!\AppData\Local>> "!terminal_script!"
echo set PATH=%%~dp0!gpg_w32_bin_dir!;%%PATH%%>> "!terminal_script!" echo set PATH=%%~dp0!gpg_w32_bin_dir!;%%PATH%%>> "!terminal_script!"
echo set PATH=%%~dp0!bin_dir!;%%PATH%%>> "!terminal_script!" echo set PATH=%%~dp0!bin_dir!;%%PATH%%>> "!terminal_script!"
if !install_clink! == 1 ( REM Clink
if !install_git! == 1 ( echo set CLINK_PATH=%%~dp0!clink_completions_dir!>> "!terminal_script!
echo set CLINK_PATH=%%~dp0!clink_completions_dir!>> "!terminal_script!
)
)
if !install_fzf! == 1 ( REM FZF
echo set FZF_DEFAULT_OPTS=--multi --layout=reverse>> "!terminal_script!" echo set FZF_DEFAULT_OPTS=--multi --layout=reverse>> "!terminal_script!"
REM Use RG for FZF to make it ultra fast REM Use RG for FZF to make it ultra fast
if !install_ripgrep! == 1 ( echo set FZF_DEFAULT_COMMAND=rg --files --no-ignore-vcs --hidden>> "!terminal_script!"
echo set FZF_DEFAULT_COMMAND=rg --files --no-ignore-vcs --hidden>> "!terminal_script!"
)
)
if !install_git! == 1 ( REM Git
echo set PATH=%%~dp0!git_install_dir!\cmd;%%PATH%%>> "!terminal_script!" echo set PATH=%%~dp0!git_install_dir!\cmd;%%PATH%%>> "!terminal_script!"
echo set PATH=%%~dp0!git_install_dir!\mingw64\bin;%%PATH%%>> "!terminal_script!" echo set PATH=%%~dp0!git_install_dir!\mingw64\bin;%%PATH%%>> "!terminal_script!"
echo set PATH=%%~dp0!git_install_dir!\usr\bin;%%PATH%%>> "!terminal_script!" echo set PATH=%%~dp0!git_install_dir!\usr\bin;%%PATH%%>> "!terminal_script!"
)
if !install_gvim! == 1 ( echo set PATH=%%~dp0!gvim_dir!;%%PATH%%>> "!terminal_script!" ) REM GVim/Clang/MinGW/NodeJS
if !install_llvm_clang! == 1 ( echo set PATH=%%~dp0!llvm_bin_dir!;%%PATH%%>> "!terminal_script!" ) echo set PATH=%%~dp0!gvim_dir!;%%PATH%%>> "!terminal_script!"
if !install_mingw64! == 1 ( echo set PATH=%%~dp0!mingw_bin_dir!;%%PATH%%>> "!terminal_script!" ) echo set PATH=%%~dp0!llvm_bin_dir!;%%PATH%%>> "!terminal_script!"
if !install_nodejs! == 1 ( echo set PATH=%%~dp0!nodejs_dir!;%%PATH%%>> "!terminal_script!" ) echo set PATH=%%~dp0!mingw_bin_dir!;%%PATH%%>> "!terminal_script!"
echo set PATH=%%~dp0!nodejs_dir!;%%PATH%%>> "!terminal_script!"
if !install_python3! == 1 ( REM Python3
echo set PATH=%%~dp0!python_bin_dir!;%%PATH%%>> "!terminal_script!" echo set PATH=%%~dp0!python_bin_dir!;%%PATH%%>> "!terminal_script!"
echo set PATH=%%~dp0!python_scripts_bin_dir!;%%PATH%%>> "!terminal_script!" echo set PATH=%%~dp0!python_scripts_bin_dir!;%%PATH%%>> "!terminal_script!"
echo set PYTHONHOME=%%~dp0!python_bin_dir!>> "!terminal_script!" echo set PYTHONHOME=%%~dp0!python_bin_dir!>> "!terminal_script!"
)
echo set PATH=%%~dp0!zip7_dir!;%%PATH%%>> "!terminal_script!" echo set PATH=%%~dp0!zip7_dir!;%%PATH%%>> "!terminal_script!"
echo if exist "%%~dp0!msvc_script!" call "%%~dp0!msvc_script!">> "!terminal_script!"
REM MSVC
echo call "%%~dp0!msvc_dir!\setup.bat">> "!terminal_script!"
echo if exist "%%~dp0win32_terminal_user_config.bat" call "%%~dp0win32_terminal_user_config.bat">> "!terminal_script!" echo if exist "%%~dp0win32_terminal_user_config.bat" call "%%~dp0win32_terminal_user_config.bat">> "!terminal_script!"
if !install_wezterm! == 1 ( REM WezTerm
echo start "" /MAX "%%~dp0!wezterm_exe!">> "!terminal_script!" echo start "" /MAX "%%~dp0!wezterm_exe!">> "!terminal_script!"
echo exit>> "!terminal_script!" echo exit>> "!terminal_script!"
)
REM ---------------------------------------------------------------------------- REM ----------------------------------------------------------------------------
REM Background Application Scripts REM Background Application Scripts
REM ---------------------------------------------------------------------------- REM ----------------------------------------------------------------------------
set terminal_script=!root_dir!\win32_start_background_apps.bat set terminal_script=!root_dir!\win32_start_background_apps.bat
echo @echo off> "!terminal_script!" echo @echo off> "!terminal_script!"
if !install_everything_void_tools! == 1 echo start "" "%%~dp0!everything_dir!\everything.exe">> "!terminal_script!" echo start "" "%%~dp0!everything_dir!\everything.exe">> "!terminal_script!"
if !install_keypirinha! == 1 echo start "" "%%~dp0!keypirinha_dir!\keypirinha.exe">> "!terminal_script!" echo start "" "%%~dp0!keypirinha_dir!\keypirinha.exe">> "!terminal_script!"
REM ---------------------------------------------------------------------------- REM ----------------------------------------------------------------------------
REM CTags Helper Script REM CTags Helper Script

View File

@ -1,41 +0,0 @@
@echo off
REM ----------------------------------------------------------------------------
REM Installation Configuration
REM ----------------------------------------------------------------------------
REM Set the 0 or 1 to enable or disable installation of a package
set install_wezterm=1
REM ----------------------------------------------------------------------------
REM Programming
REM ----------------------------------------------------------------------------
set install_git=1
set install_llvm_clang=1
set install_mingw64=1
set install_nodejs=1
set install_python3=1
set install_renderdoc=1
set install_zig=1
REM ----------------------------------------------------------------------------
REM QoL/Tools
REM ----------------------------------------------------------------------------
set install_clink=1
set install_dependency_walker=1
set install_everything_void_tools=1
set install_fzf=1
set install_gvim=1
set install_imhex=1
set install_joplin=1
set install_keypirinha=1
set install_mobaxterm=1
set install_ooshutup10=1
set install_process_hacker=1
set install_ripgrep=1
REM ----------------------------------------------------------------------------
REM Ethereum
REM ----------------------------------------------------------------------------
set install_geth=1
set install_remix_ide=1
set install_solidity=1