Skip to content

Instantly share code, notes, and snippets.

@dottharun
Last active August 31, 2024 07:59
Show Gist options
  • Save dottharun/6a5e3149bc86f63ea6ad15ba9ff3c72d to your computer and use it in GitHub Desktop.
Save dottharun/6a5e3149bc86f63ea6ad15ba9ff3c72d to your computer and use it in GitHub Desktop.
Js like clang-format - without leaving off the features from clang-format
AlignAfterOpenBracket: BlockIndent
AlignArrayOfStructures: Left
AlignConsecutiveAssignments: true
AlignConsecutiveDeclarations: true
AlignConsecutiveMacros: true
AlignEscapedNewlines: Left
AlignOperands: Align
AlignTrailingComments: true
AllowAllArgumentsOnNextLine: false
AllowAllParametersOfDeclarationOnNextLine: false
AllowShortBlocksOnASingleLine: Empty
AllowShortFunctionsOnASingleLine: Empty
AllowShortIfStatementsOnASingleLine: Always
BinPackArguments: false
BinPackParameters: false
BreakBeforeBinaryOperators: NonAssignment
BreakConstructorInitializers: AfterColon
BreakStringLiterals: true
ColumnLimit: 80
ConstructorInitializerIndentWidth: 4
ContinuationIndentWidth: 4
Cpp11BracedListStyle: true
FixNamespaceComments: false
IncludeBlocks: Regroup
IncludeCategories:
- Regex: '"[[:alnum:]._-]+"'
Priority: 1
SortPriority: 1
- Regex: '^((<|").*/)'
Priority: 2
SortPriority: 2
- Regex: "<[[:alnum:]._-]+>"
Priority: 3
SortPriority: 3
IndentCaseLabels: true
IndentPPDirectives: BeforeHash
IndentWidth: 4
NamespaceIndentation: All
PenaltyReturnTypeOnItsOwnLine: 200
PointerAlignment: Left
ReflowComments: True
SortIncludes: true
SortUsingDeclarations: false
SpacesInContainerLiterals: false
TabWidth: 4
UseTab: Never
@dottharun
Copy link
Author

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment