From 8282404642c28b3d1373aa491219c16a0fc3b557 Mon Sep 17 00:00:00 2001 From: Ly Date: Wed, 26 Apr 2017 16:03:38 -0400 Subject: [PATCH 1/2] add instruction for getting code coverage to work on MacOS. --- .gitignore | 90 +++++++++++++++++++++++++++++++++++++++++++++++ .idea/cppbase.iml | 2 ++ .idea/misc.xml | 4 +++ .idea/modules.xml | 8 +++++ .idea/vcs.xml | 6 ++++ README.md | 5 +++ 6 files changed, 115 insertions(+) create mode 100644 .idea/cppbase.iml create mode 100644 .idea/misc.xml create mode 100644 .idea/modules.xml create mode 100644 .idea/vcs.xml diff --git a/.gitignore b/.gitignore index 6f1f79c..4261ddb 100644 --- a/.gitignore +++ b/.gitignore @@ -41,3 +41,93 @@ external # System files .DS_Store + +### CLion ### +# Covers JetBrains IDEs: IntelliJ, RubyMine, PhpStorm, AppCode, PyCharm, CLion, Android Studio and Webstorm +# Reference: https://intellij-support.jetbrains.com/hc/en-us/articles/206544839 + +# User-specific stuff: +.idea/**/workspace.xml +.idea/**/tasks.xml +.idea/dictionaries + +# Sensitive or high-churn files: +.idea/**/dataSources/ +.idea/**/dataSources.ids +.idea/**/dataSources.xml +.idea/**/dataSources.local.xml +.idea/**/sqlDataSources.xml +.idea/**/dynamic.xml +.idea/**/uiDesigner.xml + +# Gradle: +.idea/**/gradle.xml +.idea/**/libraries + +# CMake +cmake-build-debug/ + +# Mongo Explorer plugin: +.idea/**/mongoSettings.xml + +## File-based project format: +*.iws + +## Plugin-specific files: + +# IntelliJ +/out/ + +# mpeltonen/sbt-idea plugin +.idea_modules/ + +# JIRA plugin +atlassian-ide-plugin.xml + +# Cursive Clojure plugin +.idea/replstate.xml + +# Crashlytics plugin (for Android Studio and IntelliJ) +com_crashlytics_export_strings.xml +crashlytics.properties +crashlytics-build.properties +fabric.properties + +### Intellij ### +# Covers JetBrains IDEs: IntelliJ, RubyMine, PhpStorm, AppCode, PyCharm, CLion, Android Studio and Webstorm +# Reference: https://intellij-support.jetbrains.com/hc/en-us/articles/206544839 + +# User-specific stuff: + +# Sensitive or high-churn files: + +# Gradle: + +# CMake + +# Mongo Explorer plugin: + +## File-based project format: + +## Plugin-specific files: + +# IntelliJ + +# mpeltonen/sbt-idea plugin + +# JIRA plugin + +# Cursive Clojure plugin + +# Crashlytics plugin (for Android Studio and IntelliJ) + +### Intellij Patch ### +# Comment Reason: https://github.com/joeblau/gitignore.io/issues/186#issuecomment-215987721 + +# *.iml +# modules.xml +# .idea/misc.xml +# *.ipr + +# Sonarlint plugin +.idea/sonarlint diff --git a/.idea/cppbase.iml b/.idea/cppbase.iml new file mode 100644 index 0000000..f08604b --- /dev/null +++ b/.idea/cppbase.iml @@ -0,0 +1,2 @@ + + \ No newline at end of file diff --git a/.idea/misc.xml b/.idea/misc.xml new file mode 100644 index 0000000..79b3c94 --- /dev/null +++ b/.idea/misc.xml @@ -0,0 +1,4 @@ + + + + \ No newline at end of file diff --git a/.idea/modules.xml b/.idea/modules.xml new file mode 100644 index 0000000..3fa1629 --- /dev/null +++ b/.idea/modules.xml @@ -0,0 +1,8 @@ + + + + + + + + \ No newline at end of file diff --git a/.idea/vcs.xml b/.idea/vcs.xml new file mode 100644 index 0000000..94a25f7 --- /dev/null +++ b/.idea/vcs.xml @@ -0,0 +1,6 @@ + + + + + + \ No newline at end of file diff --git a/README.md b/README.md index 88fcce5..d6448ea 100644 --- a/README.md +++ b/README.md @@ -85,6 +85,11 @@ Pass these options either directly to the `cmake ..` command, e.g., to build the cmake -DPROJECT_NAME= -DBUILD_TESTS=on .. +Run this command to get code coverage working: + + cmake -DPROJECT_NAME= -DBUILD_DOXYGEN_DOCS=on -DBUILD_DEPENDENCIES=on -DBUILD_TESTS=on -DBUILD_COVERAGE_ANALYSIS=on -DCMAKE_BUILD_TYPE=coverage .. && cmake --build . + + N.B.: Toggling options to build tests using `ccmake` does not work correctly, as the necessarily libraries are not download automagically! Project structure From d54211b96957e505bfe3475d05dbd032457df0fb Mon Sep 17 00:00:00 2001 From: Ly Date: Wed, 26 Apr 2017 16:39:56 -0400 Subject: [PATCH 2/2] update link to coverity and coveralls --- .travis.yml | 6 +++--- README.md | 2 +- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/.travis.yml b/.travis.yml index 1c96221..43ee1fc 100644 --- a/.travis.yml +++ b/.travis.yml @@ -12,7 +12,7 @@ compiler: env: global: - - secure: "aMh+niXXk2m2YvuHC/xVo67wm9hw1+/yUnoqBxPmK5hVzWTefSjYM+sNCZBxybskFg04aBcNt6BycAeyp4+nhiYbw2x45Sxp60Qk6u1h9m4+dvisxCZuftOt8ZbGxCKxXtbANqOg9b7b0b6986506SPD8d7kXG+Q99tN9kf71fE=" + - secure: "gD+vZ7FYKPl9txdOn4QBwU+xGZzUehczAs5M45KqP8IOwOU2v4RDS2b++xqkDtGm1BYmvfM3513sbN4XUZztZ1NElj+wS8mcVjjsnfwxxw50vuFeQoN4RTY078Yv3wIYZ5rq3g74JoSIwMC8WcqRUd4i3ka7OYwAUR88ZEDhjGEyUNFUtXgQV3YUp5B40cG0oS7afGMO2psAa58pZbkRa76PdSYs5xGNG4gh745gJ9KaSj4wDuWM6zCfkE2o//e1BBsRyswjP2jPd0gPxHiIto9kCNgPombwDHHcemaBTVDVKvrsN1P1opvJbXtNZ3B8Wgd7rgAGT6znL1RsWQ9lPY2YnHitQGCn1UCI61qqbqnM1P10vDxd2h4wmQKrvZy4TYXMzjgBF42BVb/dOCGJOOKmKyjYFddnAP6eXvNhcEQvBLI7CuHt7d1JpRWIcSNYfvsm4ehINfjETQWOQtJusZy0kwZEJOorjrg71idNh9HwlVEXgyVuDw4YMsJk8yvrSZ7DF2CQ/LMKQTS/r+/qk7qKLNkpU190A+iLquTJ17VARVQW/CrP+KyIUXP6gTA+LMZKOSmcl4XVZthPpoyD+29vOYoVwXLWy9sFjxDfUVpy82Ws/8+qXh/6n9VLcQ3p0AHY7dtHnKXgU2uXpBN63/sy145DfPfmu3IO8rAV6Oc=" matrix: - BUILD_TYPE=Debug - BUILD_TYPE=Release @@ -27,9 +27,9 @@ matrix: addons: coverity_scan: project: - name: "kartikkumar/cppbase" + name: "imvuong/cppbase" description: "Build submitted via Travis CI" - notification_email: me@kartikkumar.com + notification_email: imvuong@gmail.com build_command_prepend: "mkdir build; cd build; cmake -DPROJECT_NAME=cppbase -DCMAKE_BUILD_TYPE=$BUILD_TYPE -DBUILD_TESTS=on .." build_command: "make" branch_pattern: coverity_scan diff --git a/README.md b/README.md index d6448ea..eae94fa 100644 --- a/README.md +++ b/README.md @@ -1,7 +1,7 @@ cppbase === -\cond [![MIT license](http://img.shields.io/badge/license-MIT-brightgreen.svg)](http://opensource.org/licenses/MIT) [![Build Status](https://travis-ci.org/kartikkumar/cppbase.svg?branch=master)](https://travis-ci.org/kartikkumar/cppbase)[![Coverity Scan Build Status](https://scan.coverity.com/projects/3686/badge.svg)](https://scan.coverity.com/projects/3686) [![Coverage Status](https://coveralls.io/repos/github/kartikkumar/cppbase/badge.svg?branch=master)](https://coveralls.io/github/kartikkumar/cppbase?branch=master) \endcond +\cond [![MIT license](http://img.shields.io/badge/license-MIT-brightgreen.svg)](http://opensource.org/licenses/MIT) [![Build Status](https://travis-ci.org/imvuong/cppbase.svg?branch=master)](https://travis-ci.org/imvuong/cppbase)[![Coverity Scan Build Status](https://scan.coverity.com/projects/12565/badge.svg)](https://scan.coverity.com/projects/12565) [![Coverage Status](https://coveralls.io/repos/github/imvuong/cppbase/badge.svg?branch=master)](https://coveralls.io/github/imvuong/cppbase?branch=master) \endcond `cppbase` is a template for a simple CMake-based C++ project: it can be used as the basis for new projects. An example CMake module is available to make it easy to include your project in other projects (should be customized): [Findcppbase.cmake](https://github.com/kartikkumar/cmake-modules/Modules/Findcppbase.cmake).