 					grouped["other"].count++
 					grouped["other"].effort += commit.effort
 	
-	if program.group?
-		outputSummary data, total, grouped
-	else
-		outputSummary data, total
+	switch program.output
+		when "ascii" then outputAscii data, total, grouped
+		when "csv" then outputCsv data, total, grouped
 	
 	process.exit()
 	

spawn = childProcess.spawn
cliTable = require "cli-table"

outputPossibilities = ["csv", "ascii"]

defaultOutputFormat = outputPossibilities[0]
defaultPauseTime = 20

	return "#{h}:#{m}:#{s}"
	

outputAscii = (data, total, grouped) ->
	table = new cliTable
		head: ['Issue', 'Time spent', 'Commit count']
		colWidth: [100,100,100]
