File: create_cppcheck_report

package info (click to toggle)
widelands 1%3A17-3
  • links: PTS, VCS
  • area: main
  • in suites: wheezy
  • size: 332,404 kB
  • sloc: cpp: 104,978; python: 3,073; ada: 855; sh: 435; makefile: 225
file content (12 lines) | stat: -rwxr-xr-x 1,441 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
#!/bin/bash
FILE=cppcheck_report.xhtml
echo "<?xml version=\"1.0\" encoding=\"us-ascii\"?>"                                                                     >  $FILE
echo "<!DOCTYPE html PUBLIC \"-//W3C//DTD XHTML 1.0 Strict//EN\" \"http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd\">" >> $FILE
echo "<html xmlns=\"http://www.w3.org/1999/xhtml\">"                                                                     >> $FILE
echo "<head><title>cppcheck error report for Widelands C++ source code</title></head>"                                   >> $FILE
echo "<body>"                                                                                                            >> $FILE
echo "<div>"                                                                                                             >> $FILE
cppcheck --force --quiet --enable=all -I src src 2>&1 | sed "s@^\[\(.*\):\([[:digit:]]\+\)\]: \(.*\)\$@<a href=\"http://bazaar.launchpad.net/%7Ewidelands-dev/widelands/trunk/annotate/head%3A/\1\?#L\2\">\1:\2</a>: \3<br/>@" >> $FILE
echo "</div>"                                                                                                            >> $FILE
echo "</body>"                                                                                                           >> $FILE
echo "</html>"                                                                                                           >> $FILE