Bonjour,
je cherche a faire une version wapt (python) de mon script batch
quelle instruction via la lib wapt/python me permet de recupere la build comme le fait mon script?
:
@echo off echo installation patch imprimante for /f "tokens=4-7 delims=[.] " %%i in ('ver') do @(if %%i==Version (set version=%%j.%%k.%%l) else (set version=%%i.%%j.%%k))
if "%version%" == "10.0.19042" (GOTO :20H2) if "%version%" == "10.0.19041" (GOTO :2004) if "%version%" == "10.0.18363" (GOTO :1909) if "%version%" == "10.0.18362" (GOTO :1903) if "%version%" == "10.0.17763" (GOTO :1809) if "%version%" == "10.0.17134" (GOTO :1803)
:20H2 echo Version Windows 10 Version 20H2 detectee echo installation du patch : wusa.exe windows10.0-kb5001649-2004-20H2.msu /quiet /norestart GOTO END
:2004 echo Windows 10 Version 2004 detectee echo installation du patch : wusa.exe windows10.0-kb5001649-2004-20H2.msu /quiet /norestart GOTO END
:1909 echo Windows 10 Version 1909 detectee echo installation du patch : wusa.exe windows10.0-kb5001648-1909.msu /quiet /norestart GOTO END
:1903 echo Windows 10 Version 1903 detectee GOTO END
:1809 echo Windows 10 Version 1809 detectee echo installation du patch : wusa.exe windows10.0-kb5001638-1809.msu /quiet /norestart GOTO END
:1803 echo Windows 10 Version 1803 detectee echo installation du patch : GOTO END
:END exit
Merci;