Changes

Ninite

172 bytes added, 15:58, 19 March 2013
A script to check the Ninite logs
) else (
set ninitelogfile="%~f1"
)
 
:checklogfileexists
if not exist %ninitelogfile% (
goto nonexistinglogfile
)
:: "OK" or "Skipped (up to date)" matching the end of any subequent line
:: The regular expression captures these conditions.
for /f "tokens=*" %%g in ('findstr /V /N /I /E /R "OK$ ^Partial$ Skipped.(up.to.date)$ Skipped.(installed.version.is.newer)$" %ninitelogfile%') do set result="%%g"
:: If there are any values in this variable then the log file has failed
if not [%result%] == [] ( goto failrestoffile )
::echo paramerror
exit /B 1
 
:nonexistinglogfile
::nonexistinglogfile
exit /B 2
:failfirstline
::echo failfirstline
exit /B 23
:failrestoffile
::echo failrestoffile
exit /B 34
</source>
[[Category:Wpkg software management]][[Category:Software]][[Category:Laptops]]