-
Notifications
You must be signed in to change notification settings - Fork 3
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
210 changed files
with
18,839 additions
and
17,411 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,45 @@ | ||
BasedOnStyle: Google | ||
ColumnLimit: 120 | ||
IndentWidth: 4 | ||
|
||
# This will make access modifiers (public/protected/private) sit on the same indentation as `class` keyword | ||
AccessModifierOffset: -4 | ||
|
||
# Arguments, parameters and construction initializer are broken as following: | ||
# - Try to fit everything into single line (controlled by ColumnLimit). | ||
# - If it doesn't fit, break immediately after open bracket (in case of arguments and parameters) | ||
# or after colon in case of constructor initializers. | ||
# - Try to fit everything else into the second line. | ||
# - If it doesn't fit in second line, then each argument, parameter or initializer will sit in its own line. | ||
AlignAfterOpenBracket: AlwaysBreak | ||
AlignConsecutiveAssignments: true | ||
AlignConsecutiveBitFields: true | ||
AlignConsecutiveDeclarations: true | ||
AlignTrailingComments: true | ||
AlignEscapedNewlines: Left | ||
AlignOperands: true | ||
BinPackArguments: false | ||
BinPackParameters: false | ||
|
||
# When constructor initializers exist in the constructor definition, leave the colon as last thing on the original | ||
# line instead of putting it on the next line. | ||
BreakConstructorInitializers: AfterColon | ||
|
||
# Pointer and reference alignment | ||
DerivePointerAlignment: true | ||
PointerAlignment: Left | ||
ReferenceAlignment: Left | ||
|
||
# Disallow single statements after if/else/for/while/do without curly braces. | ||
InsertBraces: true | ||
BreakBeforeBraces: Attach | ||
|
||
# Separate definition blocks, including classes, structs, enums, and functions. | ||
SeparateDefinitionBlocks: Always | ||
SpaceBeforeCpp11BracedList: true | ||
SpacesBeforeTrailingComments: 1 | ||
SpacesInAngles: Never | ||
AllowShortLoopsOnASingleLine: true | ||
AllowShortBlocksOnASingleLine: true | ||
RemoveSemicolon: true | ||
SortUsingDeclarations: LexicographicNumeric |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,28 @@ | ||
# Run Pre-commit Hooks | ||
name: Run Pre-commit Hooks | ||
|
||
on: | ||
workflow_dispatch: | ||
pull_request: | ||
push: | ||
branches: ["main"] | ||
|
||
jobs: | ||
pre-commit: | ||
name: Run Pre-commit Hooks | ||
runs-on: ubuntu-latest | ||
steps: | ||
- name: Checkout code | ||
uses: actions/checkout@v4 | ||
with: | ||
fetch-depth: 0 # Fetch all history so 'origin/main' is available | ||
|
||
- name: Set up Python | ||
uses: actions/setup-python@v4 | ||
with: | ||
python-version: 3.8 | ||
|
||
- name: Run Pre-commit and Fix Issues | ||
uses: pre-commit/action@v3.0.1 | ||
with: | ||
extra_args: "--from-ref origin/main --to-ref HEAD" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,27 @@ | ||
repos: | ||
- repo: https://github.com/pre-commit/mirrors-clang-format | ||
rev: v19.1.7 | ||
hooks: | ||
- id: clang-format | ||
args: ["-style=file"] | ||
- repo: https://github.com/psf/black-pre-commit-mirror | ||
rev: 24.8.0 | ||
hooks: | ||
- id: black | ||
language_version: python3 | ||
- repo: https://github.com/adrienverge/yamllint | ||
rev: v1.35.1 | ||
hooks: | ||
- id: yamllint | ||
exclude: ^(?!\.github/).* # Only include files in .github/ | ||
- repo: https://github.com/espressif/check-copyright/ | ||
rev: v1.0.3 | ||
hooks: | ||
- id: check-copyright | ||
args: ['--config', 'infra/check_copyright_config.yaml', "--ignore", ""] | ||
- repo: https://github.com/pre-commit/pre-commit-hooks | ||
rev: v3.4.0 | ||
hooks: | ||
- id: trailing-whitespace | ||
- id: end-of-file-fixer | ||
- id: check-added-large-files |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
--- | ||
|
||
extends: default | ||
|
||
rules: | ||
# yaml documents should start optionally with --- | ||
document-start: disable | ||
line-length: | ||
max: 120 | ||
# the "on:" is detected as truthy value and spawns a false warning | ||
truthy: disable |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.