for /F "tokens=1,* delims==" %%i in ('findstr "version= " file.ini') do ( set "versionVar=%%~i" set "versionVal=%%~j" set sequence=%%~j+1 ) for /f "tokens=1,*delims=]" %%i in ('type "%file%" ^| find /v /n "" ^& break^>%file%') do ( set "line=%%j" if "!line!" == "!versionVar!=!versionVal!" set line=!versionVar!=!sequence! echo(!line!>>!file! )
var
This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)