Change in flashrom[master]: Add .clang-format to help with patch formatting
Vadim Bendebury has uploaded this change for review. ( https://review.coreboot.org/c/flashrom/+/38208 ) Change subject: Add .clang-format to help with patch formatting ...................................................................... Add .clang-format to help with patch formatting This is a copy from the coreboot tree, could be tweaked to better match the flashrom tree if there are any differences. Once this file is in place a script could be deployed which would format only new/changed lines in git patches. Change-Id: I2306f9fa56caca2b1572f55a02c53fe10f51b7ad --- A .clang-format 1 file changed, 21 insertions(+), 0 deletions(-) git pull ssh://review.coreboot.org:29418/flashrom refs/changes/08/38208/1 diff --git a/.clang-format b/.clang-format new file mode 100644 index 0000000..5c8aa3c --- /dev/null +++ b/.clang-format @@ -0,0 +1,21 @@ +BasedOnStyle: LLVM +Language: Cpp +IndentWidth: 8 +UseTab: Always +BreakBeforeBraces: Linux +AllowShortIfStatementsOnASingleLine: false +IndentCaseLabels: false +SortIncludes: false +ContinuationIndentWidth: 8 +ColumnLimit: 96 +AlwaysBreakBeforeMultilineStrings: true +AllowShortLoopsOnASingleLine: false +AllowShortFunctionsOnASingleLine: false +AlignEscapedNewlinesLeft: false +AlignTrailingComments: true +AllowAllParametersOfDeclarationOnNextLine: false +AlignAfterOpenBracket: true +SpaceAfterCStyleCast: false +MaxEmptyLinesToKeep: 2 +BreakBeforeBinaryOperators: NonAssignment +BreakStringLiterals: false -- To view, visit https://review.coreboot.org/c/flashrom/+/38208 To unsubscribe, or for help writing mail filters, visit https://review.coreboot.org/settings Gerrit-Project: flashrom Gerrit-Branch: master Gerrit-Change-Id: I2306f9fa56caca2b1572f55a02c53fe10f51b7ad Gerrit-Change-Number: 38208 Gerrit-PatchSet: 1 Gerrit-Owner: Vadim Bendebury <vbendeb@chromium.org> Gerrit-MessageType: newchange
Edward O'Callaghan has posted comments on this change. ( https://review.coreboot.org/c/flashrom/+/38208 ) Change subject: Add .clang-format to help with patch formatting ...................................................................... Patch Set 1: How much of the tree in it's current state conforms? -- To view, visit https://review.coreboot.org/c/flashrom/+/38208 To unsubscribe, or for help writing mail filters, visit https://review.coreboot.org/settings Gerrit-Project: flashrom Gerrit-Branch: master Gerrit-Change-Id: I2306f9fa56caca2b1572f55a02c53fe10f51b7ad Gerrit-Change-Number: 38208 Gerrit-PatchSet: 1 Gerrit-Owner: Vadim Bendebury <vbendeb@chromium.org> Gerrit-Reviewer: Edward O'Callaghan <quasisec@chromium.org> Gerrit-Reviewer: Nico Huber <nico.h@gmx.de> Gerrit-Reviewer: Vadim Bendebury <vbendeb@chromium.org> Gerrit-Reviewer: build bot (Jenkins) <no-reply@coreboot.org> Gerrit-Comment-Date: Mon, 06 Jan 2020 06:43:27 +0000 Gerrit-HasComments: No Gerrit-Has-Labels: No Gerrit-MessageType: comment
Edward O'Callaghan has posted comments on this change. ( https://review.coreboot.org/c/flashrom/+/38208 ) Change subject: Add .clang-format to help with patch formatting ...................................................................... Patch Set 1: (1 comment) https://review.coreboot.org/c/flashrom/+/38208/1//COMMIT_MSG Commit Message: https://review.coreboot.org/c/flashrom/+/38208/1//COMMIT_MSG@16 PS1, Line 16: s/o line -- To view, visit https://review.coreboot.org/c/flashrom/+/38208 To unsubscribe, or for help writing mail filters, visit https://review.coreboot.org/settings Gerrit-Project: flashrom Gerrit-Branch: master Gerrit-Change-Id: I2306f9fa56caca2b1572f55a02c53fe10f51b7ad Gerrit-Change-Number: 38208 Gerrit-PatchSet: 1 Gerrit-Owner: Vadim Bendebury <vbendeb@chromium.org> Gerrit-Reviewer: Edward O'Callaghan <quasisec@chromium.org> Gerrit-Reviewer: Nico Huber <nico.h@gmx.de> Gerrit-Reviewer: Vadim Bendebury <vbendeb@chromium.org> Gerrit-Reviewer: build bot (Jenkins) <no-reply@coreboot.org> Gerrit-Comment-Date: Mon, 06 Jan 2020 06:43:51 +0000 Gerrit-HasComments: Yes Gerrit-Has-Labels: No Gerrit-MessageType: comment
Hello Edward O'Callaghan, build bot (Jenkins), Nico Huber, I'd like you to reexamine a change. Please visit https://review.coreboot.org/c/flashrom/+/38208 to look at the new patch set (#2). Change subject: Add .clang-format to help with patch formatting ...................................................................... Add .clang-format to help with patch formatting This is a copy from the coreboot tree, could be tweaked to better match the flashrom tree if there are any differences. Once this file is in place a script could be deployed which would format only new/changed lines in git patches. Change-Id: I2306f9fa56caca2b1572f55a02c53fe10f51b7ad Signed-off-by: Vadim Bendebury <vbendeb@chromium.org> --- A .clang-format 1 file changed, 21 insertions(+), 0 deletions(-) git pull ssh://review.coreboot.org:29418/flashrom refs/changes/08/38208/2 -- To view, visit https://review.coreboot.org/c/flashrom/+/38208 To unsubscribe, or for help writing mail filters, visit https://review.coreboot.org/settings Gerrit-Project: flashrom Gerrit-Branch: master Gerrit-Change-Id: I2306f9fa56caca2b1572f55a02c53fe10f51b7ad Gerrit-Change-Number: 38208 Gerrit-PatchSet: 2 Gerrit-Owner: Vadim Bendebury <vbendeb@chromium.org> Gerrit-Reviewer: Edward O'Callaghan <quasisec@chromium.org> Gerrit-Reviewer: Nico Huber <nico.h@gmx.de> Gerrit-Reviewer: Vadim Bendebury <vbendeb@chromium.org> Gerrit-Reviewer: build bot (Jenkins) <no-reply@coreboot.org> Gerrit-MessageType: newpatchset
Vadim Bendebury has posted comments on this change. ( https://review.coreboot.org/c/flashrom/+/38208 ) Change subject: Add .clang-format to help with patch formatting ...................................................................... Patch Set 2: (1 comment) https://review.coreboot.org/c/flashrom/+/38208/1//COMMIT_MSG Commit Message: https://review.coreboot.org/c/flashrom/+/38208/1//COMMIT_MSG@16 PS1, Line 16:
s/o line Done
-- To view, visit https://review.coreboot.org/c/flashrom/+/38208 To unsubscribe, or for help writing mail filters, visit https://review.coreboot.org/settings Gerrit-Project: flashrom Gerrit-Branch: master Gerrit-Change-Id: I2306f9fa56caca2b1572f55a02c53fe10f51b7ad Gerrit-Change-Number: 38208 Gerrit-PatchSet: 2 Gerrit-Owner: Vadim Bendebury <vbendeb@chromium.org> Gerrit-Reviewer: Edward O'Callaghan <quasisec@chromium.org> Gerrit-Reviewer: Nico Huber <nico.h@gmx.de> Gerrit-Reviewer: Vadim Bendebury <vbendeb@chromium.org> Gerrit-Reviewer: build bot (Jenkins) <no-reply@coreboot.org> Gerrit-Comment-Date: Mon, 06 Jan 2020 20:49:02 +0000 Gerrit-HasComments: Yes Gerrit-Has-Labels: No Comment-In-Reply-To: Edward O'Callaghan <quasisec@chromium.org> Gerrit-MessageType: comment
David Hendricks has posted comments on this change. ( https://review.coreboot.org/c/flashrom/+/38208 ) Change subject: Add .clang-format to help with patch formatting ...................................................................... Patch Set 2: Nice! I've been wanting to do this for a while since formatting issues are a common problem especially with submissions we get from newcomers (e.g. thru Github). I'll be happy to take a closer look at this later in the week. The coding style is similar to coreboot, though we have a couple of differences for line length and tables: https://www.flashrom.org/Development_Guidelines#Coding_style As Edward said we probably need to fix up a lot of stuff that's currently in the tree. -- To view, visit https://review.coreboot.org/c/flashrom/+/38208 To unsubscribe, or for help writing mail filters, visit https://review.coreboot.org/settings Gerrit-Project: flashrom Gerrit-Branch: master Gerrit-Change-Id: I2306f9fa56caca2b1572f55a02c53fe10f51b7ad Gerrit-Change-Number: 38208 Gerrit-PatchSet: 2 Gerrit-Owner: Vadim Bendebury <vbendeb@chromium.org> Gerrit-Reviewer: David Hendricks <david.hendricks@gmail.com> Gerrit-Reviewer: Edward O'Callaghan <quasisec@chromium.org> Gerrit-Reviewer: Nico Huber <nico.h@gmx.de> Gerrit-Reviewer: Vadim Bendebury <vbendeb@chromium.org> Gerrit-Reviewer: build bot (Jenkins) <no-reply@coreboot.org> Gerrit-Comment-Date: Tue, 07 Jan 2020 00:00:39 +0000 Gerrit-HasComments: No Gerrit-Has-Labels: No Gerrit-MessageType: comment
Nico Huber has posted comments on this change. ( https://review.coreboot.org/c/flashrom/+/38208 ) Change subject: Add .clang-format to help with patch formatting ...................................................................... Patch Set 2: (1 comment) Please only merge this when the config matches the whole codebase. https://review.coreboot.org/c/flashrom/+/38208/2//COMMIT_MSG Commit Message: https://review.coreboot.org/c/flashrom/+/38208/2//COMMIT_MSG@9 PS2, Line 9: This is a copy from the coreboot tree While some people might have used this to format new coreboot code, FWIW, it has done more damage for coreboot so far. The file (and possibly clang-format itself) needs to be adapted to the existing coding style, not the other way around. Unless we want to establish a new style, ofc. -- To view, visit https://review.coreboot.org/c/flashrom/+/38208 To unsubscribe, or for help writing mail filters, visit https://review.coreboot.org/settings Gerrit-Project: flashrom Gerrit-Branch: master Gerrit-Change-Id: I2306f9fa56caca2b1572f55a02c53fe10f51b7ad Gerrit-Change-Number: 38208 Gerrit-PatchSet: 2 Gerrit-Owner: Vadim Bendebury <vbendeb@chromium.org> Gerrit-Reviewer: David Hendricks <david.hendricks@gmail.com> Gerrit-Reviewer: Edward O'Callaghan <quasisec@chromium.org> Gerrit-Reviewer: Nico Huber <nico.h@gmx.de> Gerrit-Reviewer: Vadim Bendebury <vbendeb@chromium.org> Gerrit-Reviewer: build bot (Jenkins) <no-reply@coreboot.org> Gerrit-Comment-Date: Tue, 07 Jan 2020 12:35:01 +0000 Gerrit-HasComments: Yes Gerrit-Has-Labels: No Gerrit-MessageType: comment
Vadim Bendebury has abandoned this change. ( https://review.coreboot.org/c/flashrom/+/38208 ) Change subject: Add .clang-format to help with patch formatting ...................................................................... Abandoned abandoned in favor of https://review.coreboot.org/c/flashrom/+/38673 -- To view, visit https://review.coreboot.org/c/flashrom/+/38208 To unsubscribe, or for help writing mail filters, visit https://review.coreboot.org/settings Gerrit-Project: flashrom Gerrit-Branch: master Gerrit-Change-Id: I2306f9fa56caca2b1572f55a02c53fe10f51b7ad Gerrit-Change-Number: 38208 Gerrit-PatchSet: 2 Gerrit-Owner: Vadim Bendebury <vbendeb@chromium.org> Gerrit-Reviewer: David Hendricks <david.hendricks@gmail.com> Gerrit-Reviewer: Edward O'Callaghan <quasisec@chromium.org> Gerrit-Reviewer: Nico Huber <nico.h@gmx.de> Gerrit-Reviewer: Vadim Bendebury <vbendeb@chromium.org> Gerrit-Reviewer: build bot (Jenkins) <no-reply@coreboot.org> Gerrit-CC: Paul Menzel <paulepanter@users.sourceforge.net> Gerrit-MessageType: abandon
participants (4)
-
David Hendricks (Code Review) -
Edward O'Callaghan (Code Review) -
Nico Huber (Code Review) -
Vadim Bendebury (Code Review)