- CMake-based Qt6/C++17 project
- Semantic Versioning (version.txt)
- Cross-compilation (x64 Linux and Windows via MinGW-w64), multi-configurations (debug and release) builds
- Static analysis and runtime memory check
- Unit and functional testing
- Dockerized builds
- Git pre-commit hook
- GitHub hook build triggers (via smee.io)
- Desktop notifications (just use CatLight)
- Buildsystem generation (CMake)
- Static code analysis (Cppcheck)
- Build (g++)
- Sanity check (Valgrind's memcheck)
- Unit tests and coverage (CTest)
- Functional tests (Robot Framework)
- Artifacts packaging
All commands/scripts must be run from repository's root directory.
- Linux
- Jenkins
- Docker (optional, for dockerized builds)
- g++, CMake
- MinGW-w64 + runtime environment for gcc and Wine64
- Cppcheck, Valgrind, Clang-Tidy (for analysis)
- Python3, pip and venv module (for Robot Framework)
See docker/Dockerfile for a complete list of required packages (Debian-based distros).
- Git
- Build Name and Description Setter
- Robot Framework
- Workspace Cleanup
- Multibranch Scan Webhook Trigger
- CatLight Notification
- Build (builds Qt from sources and setups build environment):
$ docker build --progress=plain -t tarikbelabbas/jenkins_agent -f docker/Dockerfile .
- Test (interactive shell):
$ docker run -it --mount type=bind,source=${PWD},target=/home/jenkins/test_ci_cd --rm tarikbelabbas/jenkins_agent bash
- Cleanup:
$ docker system prune -a -f
$ docker builder prune
- Linux build:
$ scripts/pipeline.sh --platform linux --build-type debug --qt-target-path /home/jenkins/qt_install_linux/ all
- Windows (cross-compilation) build:
$ scripts/pipeline.sh --platform windows --build-type debug --qt-target-path /home/jenkins/qt_install_windows/ --qt-host-path /home/jenkins/qt_install_linux/ all
- Install Git pre-commit hook:
$ scripts/install_pre_commit_hook.sh
- Transfer GitHub webhooks via smee to local Jenkins (port 8080):
$ scripts/smee.sh <smee-id>
- update-binfmts not working
- windows dynamic linking/library search path/windeployqt shenanigans
- max warning + warnings as error
- use clang
- other static analyzers: clang-tidy, clazy (qt-oriented analyzer)
- code formatting: clang-format, cpplint
- dependency (like catch2) management via conan?
- separate debug symbols? (+ generate symbols in release too)
- JCasC (Jenkins Configuration as Code)?
- git checkout only once (for both debug and release)
- track and monitor build times
- check if plugins exists (robot, etc.) before using them in jenkins pipeline?
- performance analysis and tracking
- refactor scripts/install.sh into a --install pipeline option
- add port argument to smee script
- c++ 20/23
- Robot Framework real world example in C / C++ sample project by Paran Lee (Apache-2.0 license)
- GitVersion CMake script for getting version from git by Amin Khozaei (no license)
- cmake toolchain file for mingw-w64 x86_64 builds on Ubuntu by Peter Spackman (no license)
