Skip to content

Figure out how to hookup clang-format #42

@igaw

Description

@igaw

I've experimented with clang-format to reformat ioctl.h. I think it would be possible to use some parts of the reformatting but it got some things pretty wrong. So currently, I don't think we should blindly apply it.

  • .clang-format
# SPDX-License-Identifier: GPL-2.0
#
# clang-format configuration file. Intended for clang-format >= 11.
#
# For more information, see:
#
#   Documentation/dev-tools/clang-format.rst
#   https://clang.llvm.org/docs/ClangFormat.html
#   https://clang.llvm.org/docs/ClangFormatStyleOptions.html
#
---
BasedOnStyle: LLVM
Language: Cpp
IndentWidth: 8
UseTab: Always
TabWidth: 8
BreakBeforeBraces: Linux
IndentCaseLabels: false
AlignTrailingComments: true
AllowShortIfStatementsOnASingleLine: false
AllowShortFunctionsOnASingleLine: false
MaxEmptyLinesToKeep: 2
  • .clang-format-include
src/nvme/ioctl.h

The above .clang-format above is just my latest version of the configuration while playing with it. So it's likely not really good at all.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    Status

    No status

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions