Source code of Windows XP (NT5)
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

81 lines
2.6 KiB

  1. set fso = CreateObject("Scripting.FileSystemObject")
  2. set rptfile = fso.CreateTextFile("builder\logs\report.txt")
  3. ' Check msm/msi build logs
  4. Function CheckVSILog(inputfile)
  5. set logfile = fso.GetFile(inputfile)
  6. set logstream = logfile.OpenAsTextStream
  7. success = False
  8. CheckVSILog = False
  9. do while logstream.AtEndOfStream <> True
  10. linein = logstream.ReadLine()
  11. if InStr(linein, "Build of 'F:\sapi5\build\sp5core\sp5core.wip' succeeded.") > 0 then
  12. success = True
  13. end if
  14. loop
  15. logstream.Close()
  16. if success = True then
  17. rptfile.WriteLine("Build of release MSI successful.")
  18. CheckVSILog = True
  19. end if
  20. end function
  21. ' Read through msdev build logs and find errors/warnings
  22. set logfile = fso.GetFile("builder\logs\chkbld.log")
  23. set errfile = fso.CreateTextFile("builder\logs\chkerrs.log", True)
  24. set warnfile = fso.CreateTextFile("builder\logs\chkwarn.log", True)
  25. set logstream = logfile.OpenAsTextStream
  26. errcount = 0
  27. do while logstream.AtEndOfStream <> True
  28. linein = logstream.ReadLine()
  29. if left(linein, 5) = "-----" then
  30. buildstep = linein
  31. elseif InStr(linein, "0 error") > 0 then
  32. ' don't do anything here
  33. elseif InStr(linein, "error") > 0 then
  34. errfile.WriteLine(buildstep)
  35. errfile.WriteLine(linein)
  36. errcount = errcount + 1
  37. elseif InStr(linein, "0 warning") > 0 then
  38. ' don't do anything here
  39. elseif InStr(linein, "warning") > 0 then
  40. warnfile.WriteLine(buildstep)
  41. warnfile.WriteLine(linein)
  42. warncount = warncount + 1
  43. end if
  44. loop
  45. rptfile.WriteLine("MSDEV debug: total error count = " & errcount)
  46. rptfile.WriteLine("MSDEV debug: total warning count = " & warncount)
  47. logstream.Close()
  48. errfile.Close()
  49. warnfile.Close()
  50. set logfile = fso.GetFile("builder\logs\frebld.log")
  51. set errfile = fso.CreateTextFile("builder\logs\freerrs.log", True)
  52. set warnfile = fso.CreateTextFile("builder\logs\frewarn.log", True)
  53. set logstream = logfile.OpenAsTextStream
  54. errcount = 0
  55. do while logstream.AtEndOfStream <> True
  56. linein = logstream.ReadLine()
  57. if left(linein, 5) = "-----" then
  58. buildstep = linein
  59. elseif InStr(linein, "0 error") > 0 then
  60. ' don't do anything here
  61. elseif InStr(linein, "error") > 0 then
  62. errfile.WriteLine(buildstep)
  63. errfile.WriteLine(linein)
  64. errcount = errcount + 1
  65. elseif InStr(linein, "0 warning") > 0 then
  66. ' don't do anything here
  67. elseif InStr(linein, "warning") > 0 then
  68. warnfile.WriteLine(buildstep)
  69. warnfile.WriteLine(linein)
  70. warncount = warncount + 1
  71. end if
  72. loop
  73. rptfile.WriteLine("MSDEV release: total error count = " & errcount)
  74. rptfile.WriteLine("MSDEV release: total warning count = " & warncount)
  75. logstream.Close()
  76. errfile.Close()
  77. warnfile.Close()
  78. rptfile.Close()