git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@12819
c3d73ce0-8a6f-49c7-b76d-
6d57e0e08775
-property gSeparator : "--------------------------------------------------------------------------------" & gEol
+property gSeparator : "-------------------------------------------------------------------------------" & gEol
--
-- Project and build success count
--
-- Project and build success count
-- Default log file name
--
set theDate to (day of (current date)) & "/" & GetMonthIndex(current date) & "/" & (year of (current date))
-- Default log file name
--
set theDate to (day of (current date)) & "/" & GetMonthIndex(current date) & "/" & (year of (current date))
-set theLogFileName to "wxMac samples " & theDate & ".log"
+set theLogFileName to "build-" & theDate & ".log"
--
-- Ask the user to select the wxWindows samples folder
--
--
-- Ask the user to select the wxWindows samples folder
--
-set theFolder to choose folder with prompt "Select the wxWindows samples folder"
+set theFolder to choose folder with prompt "Select the folder in which to build the projects"
--
-- Ask the user to choose the build log file
--
--
-- Ask the user to choose the build log file
--
-set theLogFile to choose file name with prompt "Create the wxWindows samples build log file" default name theLogFileName
+set theLogFile to choose file name with prompt "Save the build log file" default name theLogFileName
--
-- Open the log file to record the build log
--
-- Open the log file to record the build log
-- Write log file header
--
write gSeparator starting at 0 to theLogFileRef
-- Write log file header
--
write gSeparator starting at 0 to theLogFileRef
-write "wxWindows samples build log" & gEol to theLogFileRef
+write "Build log" & gEol to theLogFileRef
write gSeparator to theLogFileRef
write "start on " & ((current date) as string) & gEol to theLogFileRef
write gSeparator to theLogFileRef
write gSeparator to theLogFileRef
write "start on " & ((current date) as string) & gEol to theLogFileRef
write gSeparator to theLogFileRef
-- Close the log file
--
close access theLogFileRef
-- Close the log file
--
close access theLogFileRef
---
--- Open the file in BBEdit Lite
---
-tell application "BBEdit Lite 6.1"
- activate
- open theLogFile
-end tell
on BuildProjects(inLogFileRef, inFolder, inTarget, inRebuild)
global theProjectCount, theProjectSuccessCount
on BuildProjects(inLogFileRef, inFolder, inTarget, inRebuild)
global theProjectCount, theProjectSuccessCount
+ tell application "Finder" to update inFolder
+
try
tell application "Finder" to set theProject to ((the first file of inFolder whose name ends with gProjectSuffix) as string)
on error
try
tell application "Finder" to set theProject to ((the first file of inFolder whose name ends with gProjectSuffix) as string)
on error
if theProject is not "" then
set theProjectCount to theProjectCount + 1
if theProject is not "" then
set theProjectCount to theProjectCount + 1
- write "building project '" & (theProject as string) & "'" & gEol to inLogFileRef
+ write "building project '" & theProject & "'" & gEol to inLogFileRef
tell application "CodeWarrior IDE 4.0.4"
--
-- Open the project in CodeWarrior
--
tell application "CodeWarrior IDE 4.0.4"
--
-- Open the project in CodeWarrior
--
- open theProject as string
--
-- Change to the requested target
--
--
-- Change to the requested target
--
tell application "CodeWarrior IDE 4.0.4"
set theKind to ((messageKind of theInfo) as string)
tell application "CodeWarrior IDE 4.0.4"
set theKind to ((messageKind of theInfo) as string)
- write "*** " & theKind & " *** " & message of theInfo & gEol to inLogFileRef
+ tell me to write "*** " & theKind & " *** " & message of theInfo & gEol to inLogFileRef
try
set theFile to ((file of theInfo) as string)
on error
set theFile to ""
end try
if theFile is not "" then
try
set theFile to ((file of theInfo) as string)
on error
set theFile to ""
end try
if theFile is not "" then
- write theFile & " line " & lineNumber of theInfo & gEol to inLogFileRef
+ tell me to write theFile & " line " & lineNumber of theInfo & gEol to inLogFileRef
- write gEol to inLogFileRef
+ tell me to write gEol to inLogFileRef
end tell
if MessageKindIsError(theKind) then
end tell
if MessageKindIsError(theKind) then
return i
end if
end repeat
return i
end if
end repeat
-end GetMonthIndex
\ No newline at end of file