Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 12 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,18 @@

All notable changes to this project will be documented in this file.

## [UNRELEASED]

### Added

- Better cache support in pre-commit action.
- README for Dummy C++ Project.
- Status logging in pre-commit action.

### Fixed

- Typos in pre-commit action.

## [0.2.0] - 2026-02-11

### Added
Expand Down
2 changes: 0 additions & 2 deletions dummy_cpp_project/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -41,8 +41,6 @@

# cmake-format: on

# TODO: Will be rewritten.

cmake_minimum_required(VERSION 3.30)

# Read version from VERSION file
Expand Down
12 changes: 8 additions & 4 deletions pre-commit/action.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -27,19 +27,19 @@ name: "Pre Commit"
description: "Runs pre-commit with the given inputs."
inputs:
python-version:
description: "Version of Python to use"
description: "Version of Python to use."
required: false
default: "3.x"
use_cache:
description: "Enable or disable caching of pre-commit hooks and cppcheck"
description: "Enable or disable caching of pre-commit hooks."
required: false
default: "true"
use_cppcheck:
description: "Whether to use cppcheck or not."
required: false
default: "true"
args:
description: "Arguments given to pre-commit"
description: "Arguments given to pre-commit."
required: false
default: "--all-files"

Expand All @@ -57,8 +57,10 @@ runs:
if: inputs.use_cppcheck == 'true'
shell: bash
run: |
sudo apt-get -qq update
echo "Installing Cppcheck..."
sudo apt-get -qq -y update
sudo apt-get install -qq -y cppcheck
echo "Cppcheck Installed."

- name: Set up pre-commit cache
id: cache-pre-commit
Expand All @@ -75,5 +77,7 @@ runs:
PRE_COMMIT_HOME: ${{ github.workspace }}/.cache/pre-commit
shell: bash
run: |
echo "Running Pre Commit..."
pip install pre-commit
pre-commit run ${{ inputs.args }}
echo "All Tests Passed!"
Loading