For measuring runtime performance of ruby scripts insert the few lines below around the part you want to measure.
----
# Record Startime For performance measurments
startTime = Time.now
Main part of script goes here
#Calculate and Display Execution Time in seconds
execTime = Time.now - startTime
puts "Execution time #{execTime} seconds."
----
Thats it!
Twitter Updates
Wednesday 19 November 2008
Subscribe to:
Post Comments (Atom)
No comments:
Post a Comment