Capturing script output as a single event