Skip to content

Template repo for C/C++ projects that use CMake and Google Tests for Github Actions

License

Notifications You must be signed in to change notification settings

TomVer99/C-CPP_CMake_GTest-GithubActions

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

C(++) W/ CMake and Google Test using GitHub actions Template

C C++ CMake GitHub Actions Google Test lcov valgrind


Release GitHub commits since latest release

Maintained Issues GitHub Actions Workflow Status GitHub Actions Workflow Status

license

Description

This template is meant to be used as a starting point for C/C++ projects using CMake and Google Test.

It includes:

  • CMake setup for building a library and an executable
  • Google Test setup for unit testing
  • GitHub Actions setup for CI
    • Only runs on PRs
  • GitHub Actions setup for Code Hygiene based on the Google C++ Style Guide
    • Brackets on newlines
  • Automatic Labeling of Pull Requests
  • Code coverage analysis
    • Fails under 90%
    • Only counts /src/ files
  • Valgrind memory leak detection
    • Fails if memory leaks are detected

Requirements

  • CMake
  • GCC
  • lcov
  • Valgrind