diff --git a/.clang-format b/.clang-format new file mode 100644 index 0000000..4304af8 --- /dev/null +++ b/.clang-format @@ -0,0 +1,47 @@ +Language: Cpp +IndentWidth: 4 +BreakBeforeBraces: Custom +NamespaceIndentation: All +BraceWrapping: + AfterCaseLabel: true + AfterClass: true + AfterControlStatement: Never + AfterEnum: false + AfterFunction: true + AfterNamespace: false + AfterStruct: true + AfterUnion: true + AfterExternBlock: false + BeforeCatch: false + BeforeElse: false + BeforeLambdaBody: false + BeforeWhile: false + IndentBraces: false + SplitEmptyFunction: false + SplitEmptyRecord: false + SplitEmptyNamespace: false +SortIncludes: true +IncludeBlocks: Preserve +IncludeCategories: + - Regex: "<(.*)>" + Priority: 2 + SortPriority: 2 + - Regex: "\"(.*)\"" + Priority: 3 + SortPriority: 3 +IndentCaseLabels: true +IndentPPDirectives: BeforeHash +DerivePointerAlignment: false +PointerAlignment: Left +AllowAllConstructorInitializersOnNextLine: true +ConstructorInitializerAllOnOneLineOrOnePerLine: true +BreakConstructorInitializers: BeforeColon +FixNamespaceComments: true +AccessModifierOffset: -4 +AlignAfterOpenBracket: AlwaysBreak +ReflowComments: false +AlwaysBreakTemplateDeclarations: Yes +BinPackArguments: false +ColumnLimit: 130 +AllowShortFunctionsOnASingleLine: None +ConstructorInitializerIndentWidth: 4 \ No newline at end of file diff --git a/.clang-tidy b/.clang-tidy new file mode 100644 index 0000000..bcea84a --- /dev/null +++ b/.clang-tidy @@ -0,0 +1,34 @@ +Checks: " *, + -cppcoreguidelines-avoid-magic-numbers, + -cppcoreguidelines-macro-usage, + -misc-no-recursion, + -modernize-use-trailing-return-type, + -modernize-pass-by-value, + -readability-magic-numbers, + -llvmlibc-*, + -fuchsia-default-arguments-calls, + -altera-id-dependent-backward-branch, + -altera-unroll-loops, + -google-readability-todo, + -llvm-header-guard, + -altera-struct-pack-align, + -fuchsia-overloaded-operator, + -fuchsia-default-arguments-declarations, + -llvm-include-order, + -abseil-string-find-str-contains, + -bugprone-exception-escape, + -fuchsia-trailing-return, + -readability-static-accessed-through-instance +" + +CheckOptions: + - key: misc-non-private-member-variables-in-classes.IgnoreClassesWithAllMemberVariablesBeingPublic + value: '1' + - key: readability-identifier-length.MinimumVariableNameLength + value: 2 + - key: readability-identifier-length.MinimumParameterNameLength + value: 2 + - key: readability-identifier-length.IgnoredParameterNames + value: 'c|n|f' + - key: readability-identifier-length.IgnoredLoopCounterNames + value: 'c|i|j|k|n' \ No newline at end of file diff --git a/.gitignore b/.gitignore new file mode 100644 index 0000000..56ed07a --- /dev/null +++ b/.gitignore @@ -0,0 +1,24 @@ +#build files +build/ +**/CMakeFiles +CMake** +cmake** +!cmake +!CMakeLists.txt +Makefile + +#documentation files +/docs/ + +#binary files +*.a +*.o + +#editor dir +**/.vscode +**/.vs +**/.cache/ +compile_commands.json + +#log files +*.log \ No newline at end of file