CSV Output

The --csv option output comma-separated values summarizing the coverage of each file. Consider the following command:

gcovr --csv example_csv.csv

This generates an CSV:

filename,line_total,line_covered,line_percent,branch_total,branch_covered,branch_percent,function_total,function_covered,function_percent
example.cpp,7,6,0.857,2,1,0.5,2,2,1.0

Be carefule if you print the output of a CSV to STDOUT and redirect it to a file. According to RFC4180 the line endings must be CRLF.

New in version 5.0: Added --csv.