mike325 / cpp_starter_project

A template CMake project to get you started with C++ and tooling

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

cpp_boilerplate_project

ci codecov Language grade: C++

About cpp_boilerplate_project

This is a C++ Best Practices GitHub template for getting up and running with C++ quickly.

By default (collectively known as ENABLE_DEVELOPER_MODE)

  • Address Sanitizer and Undefined Behavior Sanitizer enabled where possible
  • Warnings as errors
  • clang-tidy and cppcheck static analysis
  • conan for dependencies

It includes

  • a basic CLI example
  • examples for fuzz, unit, and constexpr testing
  • large github action testing matrix

It requires

  • cmake
  • conan
  • a compiler

If you want a more complex example project, check out the cpp_starter_project.

Ths Boilerplate project will merge new features first, then they will be merged (as appropriate) into cpp_starter_project.

Getting Started

Use the Github template

First, click the green Use this template button near the top of this page. This will take you to Github's 'Generate Repository' page. Fill in a repository name and short description, and click 'Create repository from template'. This will allow you to create a new repository in your Github account, prepopulated with the contents of this project. Now you can clone the project locally and get to work!

git clone https://github.com/<user>/<your_new_repo>.git

Remove frameworks you're not going to use

If you know you're not going to use one or more of the optional gui/graphics frameworks (fltk, gtkmm, imgui, etc.), you can remove them with git rm:

git rm -r src/<unnecessary_framework>

More Details

Testing

See Catch2 tutorial

Fuzz testing

See libFuzzer Tutorial

About

A template CMake project to get you started with C++ and tooling

License:The Unlicense


Languages

Language:CMake 59.8%Language:C++ 18.6%Language:Dockerfile 17.2%Language:Shell 4.4%