Skip to content

Commit

Permalink
Project initialization
Browse files Browse the repository at this point in the history
  • Loading branch information
Gonzalo Diaz committed Sep 9, 2024
1 parent ea7666b commit e491552
Show file tree
Hide file tree
Showing 31 changed files with 1,501 additions and 0 deletions.
2 changes: 2 additions & 0 deletions .dockerignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
.git
build
43 changes: 43 additions & 0 deletions .editorconfig
Original file line number Diff line number Diff line change
@@ -0,0 +1,43 @@
# top-most EditorConfig file
root = true

# Unix-style newlines with a newline ending every file
[*]
charset = utf-8
end_of_line = lf
insert_final_newline = true
indent_style = space
trim_trailing_whitespace = true
indent_size = 4
max_line_length = 80

# # Already default setting
# [*.sh]
# indent_size = 4

# # Already default setting
# Same as in .clang-format
# [{*.cpp, *.hpp, *.S}]
# indent_size = 4

# # Already default setting
# [{*.ld, *.lds}]
# indent_size = 4

[*.nix]
indent_size = 2

[*.toml]
indent_size = 2

[*.yml]
indent_size = 2


[{CMakeLists.txt,*.cmake}]
indent_size = 2

[{Makefile,**.mk}]
# Use tabs for indentation (Makefiles require tabs)
indent_style = tab
indent_size = 2
43 changes: 43 additions & 0 deletions .github/ISSUE_TEMPLATE/bug_report.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,43 @@
---
name: Bug report
about: Create a report to help us improve
title: "[BUG] ..."
labels: bug
assignees: sir-gon

---

---
name: Bug report
about: Create a report to help us improve
title: ''
labels: ''
assignees: ''

---

**Describe the bug**
A clear and concise description of what the bug is.

**To Reproduce**
Steps to reproduce the behavior:

1. Go to '...'
2. Click on '....'
3. Scroll down to '....'
4. See error

**Expected behavior**
A clear and concise description of what you expected to happen.

**Screenshots**
If applicable, add screenshots to help explain your problem.

**Desktop (please complete the following information):**

- OS: [e.g. MacOS, Windows, Linux \<distribution\>]
- Version [e.g. 10]

**Additional context**
Add any other context about the problem here. Consider environment variables,
IDE (+ version), framework version, runtime version, command and parameters of execution.
19 changes: 19 additions & 0 deletions .github/dependabot.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
# To get started with Dependabot version updates, you'll need to specify which
# package ecosystems to update and where the package manifests are located.
# Please see the documentation for all configuration options:
# https://docs.github.com/github/administering-a-repository/configuration-options-for-dependency-updates
---

version: 2
updates:
# Maintain dependencies for GitHub Actions
- package-ecosystem: "github-actions"
directory: "/"
schedule:
interval: "weekly"

# Maintain dependencies for Docker
- package-ecosystem: "docker"
directory: "/"
schedule:
interval: "weekly"
58 changes: 58 additions & 0 deletions .github/workflows/cpp-coverage.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,58 @@
---

name: C++ CI Coverage

on: # yamllint disable-line rule:truthy
push:
branches: ["main"]
pull_request:
# The branches below must be a subset of the branches above
branches: ["main"]
workflow_dispatch:

jobs:
coverage:
runs-on: ubuntu-latest

steps:
- name: Checkout repository
uses: actions/checkout@692973e3d937129bcbf40652eb9f2f61becf3332 # v4

- name: Install Tools
run: |
pip install gcovr
- name: Check Tools
run: |
make --version
cmake --version
vcpkg --version
gcovr --version
- name: Install dependencies
run: |
vcpkg integrate install
vcpkg install catch2
# yamllint disable rule:line-length
- name: Build
run: |
export VCPKG_ROOT=/usr/local/share/vcpkg
cmake --preset debug -B build
cmake --preset debug \
-DCMAKE_TOOLCHAIN_FILE=/usr/local/share/vcpkg/scripts/buildsystems/vcpkg.cmake \
-DCMAKE_EXPORT_COMPILE_COMMANDS=1 \
build
cmake --build build --verbose
# yamllint enable rule:line-length

- name: Test / Coverage
run: make coverage

- name: Upload coverage reports to Codecov with GitHub Action
uses: codecov/codecov-action@v4
with:
directory: ./coverage
files: coverage.lcov
token: ${{ secrets.CODECOV_TOKEN }} # required
verbose: true # optional (default = false)
52 changes: 52 additions & 0 deletions .github/workflows/cpp.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,52 @@
---

name: C++ CI Tests

on: # yamllint disable-line rule:truthy
push:
branches: ["main"]
pull_request:
# The branches below must be a subset of the branches above
branches: ["main"]
workflow_dispatch:

jobs:
build:
runs-on: ubuntu-latest
strategy:
matrix:
os: [
"windows-latest",
"ubuntu-latest",
"macOS-latest"
]

steps:
- name: Checkout repository
uses: actions/checkout@692973e3d937129bcbf40652eb9f2f61becf3332 # v4

- name: Check Tools
run: |
make --version
cmake --version
vcpkg --version
- name: Install dependencies
run: |
vcpkg integrate install
vcpkg install catch2
# yamllint disable rule:line-length
- name: Build
run: |
export VCPKG_ROOT=/usr/local/share/vcpkg
cmake --preset debug -B build
cmake --preset debug \
-DCMAKE_TOOLCHAIN_FILE=/usr/local/share/vcpkg/scripts/buildsystems/vcpkg.cmake \
-DCMAKE_EXPORT_COMPILE_COMMANDS=1 \
build
cmake --build build --verbose
# yamllint enable rule:line-length

- name: Test
run: make test
29 changes: 29 additions & 0 deletions .github/workflows/cppcheck.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
---

name: CppCheck Lint

on: # yamllint disable-line rule:truthy
push:
branches: ["main"]
pull_request:
# The branches below must be a subset of the branches above
branches: ["main"]
workflow_dispatch:

jobs:
lint:
name: CppCheck Lint
runs-on: ubuntu-latest

steps:
- name: Checkout repository
uses: actions/checkout@692973e3d937129bcbf40652eb9f2f61becf3332 # v4

- name: Install dependencies
run: |
sudo apt-get update
sudo apt-get install cppcheck
cppcheck --version
- name: Lint
run: make test/static
Loading

0 comments on commit e491552

Please sign in to comment.