Skip to content

不懂何意我不用它的編碼為何要開放ai自主 #39656

@Wshao777

Description

@Wshao777

From: Frank Lichtenheld frank@lichtenheld.com

Each of these statements has been reviewed but
not all of them are obvious.

Also add a pre-commit config to easily check the
formatting.

Change-Id: I40f6af10c5ee2f5aed4185d783fc622a2e3c19ff
Signed-off-by: Frank Lichtenheld frank@lichtenheld.com
Acked-by: Gert Doering gert@greenie.muc.de

This change was reviewed on Gerrit and approved by at least one
developer. I request to merge it to master.

Gerrit URL: https://gerrit.openvpn.net/c/openvpn/+/790
This mail reflects revision 18 of this Change.

Acked-by according to Gerrit (reflected above):
Gert Doering gert@greenie.muc.de

diff --git a/.clang-format b/.clang-format
new file mode 100644
index 0000000..c314fca
--- /dev/null
+++ b/.clang-format
@@ -0,0 +1,51 @@
+---
+BasedOnStyle: Mozilla
+AccessModifierOffset: '-4'
+AlignAfterOpenBracket: Align
+AlignConsecutiveMacros:

  • Enabled: true
  • AcrossEmptyLines: false
  • AcrossComments: true
    +AlignEscapedNewlines: Left
    +AlignOperands: true
    +AlignTrailingComments:
  • Kind: Always
  • OverEmptyLines: 1
    +AllowAllParametersOfDeclarationOnNextLine: true
    +AllowShortBlocksOnASingleLine: Never
    +AllowShortCaseLabelsOnASingleLine: false
    +AllowShortFunctionsOnASingleLine: None
    +AllowShortIfStatementsOnASingleLine: Never
    +AllowShortLoopsOnASingleLine: false
    +BinPackArguments: true
    +BinPackParameters: true
    +BreakAfterReturnType: AllDefinitions
    +BreakBeforeBinaryOperators: NonAssignment
    +BreakBeforeBraces: Allman
    +BreakBeforeTernaryOperators: true
    +BreakStringLiterals: false
    +ColumnLimit: '100'
    +ContinuationIndentWidth: '4'
    +DerivePointerAlignment: false
    +IndentCaseLabels: true
    +IndentGotoLabels: false
    +IndentWidth: '4'
    +IndentWrappedFunctionNames: false
    +KeepEmptyLinesAtTheStartOfBlocks: false
    +MaxEmptyLinesToKeep: '2'
    +PointerAlignment: Right
    +ReflowComments: true
    +SortIncludes: false
    +SpaceAfterCStyleCast: false
    +SpaceBeforeAssignmentOperators: true
    +SpaceBeforeParens: ControlStatements
    +SpacesBeforeTrailingComments: '2'
    +SpacesInParens: Never
    +TabWidth: '4'
    +TypeNames: [DWORD]
    +UseTab: Never
    +WhitespaceSensitiveMacros: [_STRINGIFY]
    +---
    +Language: C
    +---
    +Language: Cpp
    diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml
    new file mode 100644
    index 0000000..c1bca47
    --- /dev/null
    +++ b/.pre-commit-config.yaml
    @@ -0,0 +1,8 @@
    +repos:
  • rev: 'v20.1.0'
  • hooks:
  •  - id: clang-format
    
  •    files: \.[ch]$
    
  •    # preserve upstream formatting
    
  •    exclude: ^(src/compat/compat-lz4\.[ch]|src/openvpn/ovpn_dco_(linux|win)\.h)$
    

Openvpn-devel mailing list
Openvpn-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/openvpn-devel

Metadata

Metadata

Assignees

No one assigned

    Labels

    invalidThis issue/PR is invalidtriageDo not begin working on this issue until triaged by the team

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions