-
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.
Merge pull request #14 from contour-terminal/minor-polishing
Minor polishing
- Loading branch information
Showing
9 changed files
with
274 additions
and
103 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,109 @@ | ||
--- | ||
BasedOnStyle: Microsoft | ||
AccessModifierOffset: '-2' | ||
AlignAfterOpenBracket: Align | ||
AlignConsecutiveMacros: 'true' | ||
AlignConsecutiveDeclarations: 'false' | ||
AlignEscapedNewlines: Left | ||
AlignOperands: 'true' | ||
AlignTrailingComments: 'true' | ||
AllowAllArgumentsOnNextLine: 'true' | ||
AllowAllConstructorInitializersOnNextLine: 'true' | ||
AllowAllParametersOfDeclarationOnNextLine: 'true' | ||
AllowShortBlocksOnASingleLine: 'false' | ||
AllowShortCaseLabelsOnASingleLine: 'true' | ||
AllowShortFunctionsOnASingleLine: InlineOnly | ||
AllowShortIfStatementsOnASingleLine: Never | ||
AllowShortLambdasOnASingleLine: Inline | ||
AllowShortLoopsOnASingleLine: 'false' | ||
AlwaysBreakAfterReturnType: None | ||
AlwaysBreakBeforeMultilineStrings: 'false' | ||
AlwaysBreakTemplateDeclarations: 'Yes' | ||
BinPackArguments: 'false' | ||
BinPackParameters: 'false' | ||
BreakBeforeBinaryOperators: NonAssignment | ||
BreakBeforeBraces: Custom | ||
BreakBeforeTernaryOperators: 'true' | ||
BreakConstructorInitializers: AfterColon | ||
BreakInheritanceList: AfterColon | ||
BreakStringLiterals: 'true' | ||
ColumnLimit: '110' | ||
CompactNamespaces: 'false' | ||
ConstructorInitializerAllOnOneLineOrOnePerLine: 'true' | ||
ConstructorInitializerIndentWidth: '4' | ||
ContinuationIndentWidth: '4' | ||
Cpp11BracedListStyle: 'false' | ||
DerivePointerAlignment: 'false' | ||
FixNamespaceComments: 'true' | ||
IncludeBlocks: Regroup | ||
IndentCaseLabels: true | ||
IndentPPDirectives: BeforeHash | ||
IndentWidth: '4' | ||
IndentWrappedFunctionNames: 'false' | ||
Language: Cpp | ||
MaxEmptyLinesToKeep: '1' | ||
NamespaceIndentation: Inner | ||
PenaltyBreakAssignment: '0' | ||
PointerAlignment: Left | ||
ReflowComments: 'true' | ||
SortIncludes: 'true' | ||
SortUsingDeclarations: 'true' | ||
SpaceAfterCStyleCast: 'true' | ||
SpaceAfterLogicalNot: 'false' | ||
SpaceAfterTemplateKeyword: 'true' | ||
SpaceBeforeAssignmentOperators: 'true' | ||
SpaceBeforeCpp11BracedList: 'true' | ||
SpaceBeforeCtorInitializerColon: 'false' | ||
SpaceBeforeInheritanceColon: 'false' | ||
SpaceBeforeParens: ControlStatements | ||
SpaceBeforeRangeBasedForLoopColon: 'false' | ||
SpaceInEmptyParentheses: 'false' | ||
SpacesInAngles: 'false' | ||
SpacesInCStyleCastParentheses: 'false' | ||
SpacesInContainerLiterals: 'false' | ||
SpacesInParentheses: 'false' | ||
SpacesInSquareBrackets: 'false' | ||
Standard: Cpp11 | ||
TabWidth: '4' | ||
UseTab: Never | ||
IncludeCategories: | ||
- Regex: '^<(contour)/' | ||
Priority: 0 | ||
- Regex: '^<(vtbackend)/' | ||
Priority: 1 | ||
- Regex: '^<(vtparser)/' | ||
Priority: 2 | ||
- Regex: '^<(vtpty)/' | ||
Priority: 3 | ||
- Regex: '^<(vtrasterizer)/' | ||
Priority: 4 | ||
- Regex: '^<(text_shaper)/' | ||
Priority: 5 | ||
- Regex: '^<(crispy)/' | ||
Priority: 6 | ||
- Regex: '^<(libunicode)/' | ||
Priority: 40 | ||
- Regex: '^<(fmt)/' | ||
Priority: 42 | ||
- Regex: '^<(yaml-cpp)/' | ||
Priority: 44 | ||
- Regex: '^<(range)/' | ||
Priority: 46 | ||
- Regex: '^<gsl/' | ||
Priority: 48 | ||
- Regex: '^<fontconfig/' | ||
Priority: 52 | ||
- Regex: '^<harfbuzz/' | ||
Priority: 53 | ||
- Regex: '^<(QtCore|QtGui|QtDBus|QtWidgets|QtQml|QtQuick|QtNetwork|QtMultimedia)/' | ||
Priority: 64 | ||
- Regex: '^<catch2/' | ||
Priority: 70 | ||
- Regex: '^<sys/' | ||
Priority: 80 | ||
- Regex: '^<[[:alnum:]_]+>' | ||
Priority: 81 | ||
- Regex: '<[[:alnum:]_]+\.h>' | ||
Priority: 82 | ||
- Regex: '.*' | ||
Priority: 99 |
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
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 |
---|---|---|
|
@@ -9,16 +9,36 @@ on: | |
- master | ||
|
||
jobs: | ||
ubuntu_2204: | ||
check_clang_format: | ||
name: "Check C++ style" | ||
runs-on: ubuntu-22.04 | ||
steps: | ||
- uses: actions/checkout@v3 | ||
- name: Run clang-format style check for C/C++/Protobuf programs. | ||
uses: jidicula/[email protected] | ||
with: | ||
clang-format-version: '16' | ||
check-path: '.' | ||
#exclude-regex: 'sse2neon.h' | ||
|
||
editorconfig: | ||
name: "Check editorconfig" | ||
runs-on: ubuntu-22.04 | ||
steps: | ||
- uses: actions/checkout@v2 | ||
- uses: editorconfig-checker/action-editorconfig-checker@main | ||
- run: editorconfig-checker | ||
|
||
ubuntu: | ||
strategy: | ||
fail-fast: false | ||
matrix: | ||
cxx: [20] | ||
build_type: ["RelWithDebInfo"] | ||
compiler: | ||
[ | ||
"g++-12", | ||
"clang++-14" | ||
"g++-11", | ||
"clang++-15" | ||
] | ||
name: "Ubuntu 22.04 (${{ matrix.compiler }}, C++${{ matrix.cxx }}, ${{matrix.build_type}})" | ||
runs-on: ubuntu-22.04 | ||
|
@@ -34,15 +54,30 @@ jobs: | |
- name: "update APT database" | ||
run: sudo apt -q update | ||
|
||
- name: Install Compilers | ||
run: sudo apt install -y g++-11 clang-14 | ||
- name: Set up Clang | ||
uses: egor-tensin/setup-clang@v1 | ||
with: | ||
version: 15 | ||
|
||
- name: "Download dependencies" | ||
run: sudo apt install cmake ninja-build | ||
run: sudo apt install cmake ninja-build # catch2 | ||
# workaround for broken clang on ubuntu runner until https://github.com/actions/runner-images/issues/8659 get fixed | ||
#- uses: mjp41/workaround8649@7929373c0fe5caf844d8115adccef39e3b5362e7 | ||
- name: Install Compilers | ||
run: sudo apt install -y g++-12 | ||
- name: "Cmake configure" | ||
run: cmake -S . -B build -G Ninja -D BOXED_CPP_TESTS=ON -D ENABLE_TIDY=ON -DPEDANTIC_COMPILER=ON -D CMAKE_CXX_FLAGS="-Wno-unknown-warning-option" -DCMAKE_CXX_COMPILER=${{ matrix.compiler }} -DCMAKE_CXX_STANDARD=${{ matrix.cxx }} -DCMAKE_BUILD_TYPE=${{matrix.build_type}} | ||
- name: "build " | ||
run: | | ||
cmake -S . -B build -G Ninja \ | ||
-DBOXED_CPP_TESTS=OFF \ | ||
-DENABLE_TIDY=ON \ | ||
-DPEDANTIC_COMPILER=ON \ | ||
-DCMAKE_CXX_FLAGS="-Wno-unknown-warning-option" \ | ||
-DCMAKE_CXX_COMPILER=${{ matrix.compiler }} \ | ||
-DCMAKE_CXX_STANDARD=${{ matrix.cxx }} \ | ||
-DCMAKE_BUILD_TYPE=${{matrix.build_type}} | ||
- name: "build" | ||
run: cmake --build build --parallel 3 | ||
|
||
- name: "run test" | ||
if: ${{ false }} # disabled, because of Github runner image bug in compiler-vs-stdlib | ||
run: ./build/test-boxed-cpp |
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
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
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
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.