Skip to content

Commit

Permalink
Updated to closely match ETL formatting
Browse files Browse the repository at this point in the history
  • Loading branch information
jwellbelove committed Oct 2, 2021
1 parent bb28930 commit 4a972db
Show file tree
Hide file tree
Showing 3 changed files with 50 additions and 5 deletions.
36 changes: 31 additions & 5 deletions .clang-format
Original file line number Diff line number Diff line change
@@ -1,25 +1,51 @@
---
#------------------------------------
# Configuration for clang-format v12
#------------------------------------

Language: Cpp

SortIncludes: false
SortIncludes: true

BasedOnStyle: Chromium

BreakBeforeBraces: Stroustrup
BinPackParameters: false
BitFieldColonSpacing: Both

BreakBeforeBraces: Allman
BreakConstructorInitializers: BeforeComma

AllowShortBlocksOnASingleLine: true
AllowShortBlocksOnASingleLine: false
AllowShortCaseLabelsOnASingleLine: true
AllowShortFunctionsOnASingleLine: Inline
AllowShortFunctionsOnASingleLine: None
AllowShortIfStatementsOnASingleLine: false

AllowAllArgumentsOnNextLine: true
AllowAllParametersOfDeclarationOnNextLine: true

ConstructorInitializerAllOnOneLineOrOnePerLine: 'true'
ConstructorInitializerIndentWidth: '2'

ColumnLimit: '150'
NamespaceIndentation: All
IndentPPDirectives: BeforeHash
PointerAlignment: Left
ColumnLimit: '0'
ContinuationIndentWidth: '2'
UseTab: Never
TabWidth: '2'
IndentWidth: '2'
AccessModifierOffset : '-2'
IndentCaseLabels: false
Cpp11BracedListStyle: 'true'
AlignAfterOpenBracket: Align
AlignConsecutiveDeclarations: true

#------------------------------------
# Configurations not supported by clang-format v12
#------------------------------------
# BreakInheritanceList: AfterComma
# EmptyLineBeforeAccessModifier: Always
# EmptyLineAfterAccessModifier: Always
# ReferenceAlignment: Left

...
4 changes: 4 additions & 0 deletions test/vs2019/etl.vcxproj
Original file line number Diff line number Diff line change
Expand Up @@ -8366,9 +8366,13 @@
</ItemGroup>
<ItemGroup>
<None Include="..\..\.circleci\config.yml" />
<None Include="..\..\.clang-format" />
<None Include="..\..\.gitattributes" />
<None Include="..\..\.github\workflows\clang.yml" />
<None Include="..\..\.github\workflows\gcc.yml" />
<None Include="..\..\.github\workflows\vs2019.yml" />
<None Include="..\..\.gitignore" />
<None Include="..\..\.gitmodules" />
<None Include="..\..\appveyor.yml" />
<None Include="..\..\arduino\create_arduino_library.py" />
<None Include="..\..\arduino\examples\Example_0_import_etl\Example_0_import_etl.ino" />
Expand Down
15 changes: 15 additions & 0 deletions test/vs2019/etl.vcxproj.filters
Original file line number Diff line number Diff line change
Expand Up @@ -121,6 +121,9 @@
<Filter Include="Source Files\Sanity Checks\Logs">
<UniqueIdentifier>{5b76fd56-eb83-489f-b9a6-798c07c5fa76}</UniqueIdentifier>
</Filter>
<Filter Include="Resource Files\Git">
<UniqueIdentifier>{ffb65df4-d5c7-44ab-a9c7-1150ddce2d6f}</UniqueIdentifier>
</Filter>
</ItemGroup>
<ItemGroup>
<ClInclude Include="..\..\include\etl\enum_type.h">
Expand Down Expand Up @@ -3106,6 +3109,18 @@
<None Include="..\..\arduino\examples\Vector_Examples\Example_Vector_1_simple_use\Example_Vector_1_simple_use.ino">
<Filter>ETL\Arduino\Examples\Vector_Examples\Example_Vector_1_simple_use</Filter>
</None>
<None Include="..\..\.clang-format">
<Filter>Resource Files</Filter>
</None>
<None Include="..\..\.gitattributes">
<Filter>Resource Files\Git</Filter>
</None>
<None Include="..\..\.gitignore">
<Filter>Resource Files\Git</Filter>
</None>
<None Include="..\..\.gitmodules">
<Filter>Resource Files\Git</Filter>
</None>
</ItemGroup>
<ItemGroup>
<Text Include="..\..\support\Release notes.txt">
Expand Down

0 comments on commit 4a972db

Please sign in to comment.