Skip to content

Commit

Permalink
Remove extraneous .clang-format files
Browse files Browse the repository at this point in the history
The .clang-format files in the base, debuggerd, adb, libprocinfo, and
fastboot subdirectories each differ slightly from the top level
.clang-format-2 and .clang-format-4, but not in a substantially
meaningful way, as the source files in those directories have not been
re-formatted with clang-format.  Therefore, let's reduce the
differences and use only the two top level clang-format files.

Secondly perform some small clean-up of the top level .clang-format
files.  AllowShortBlocksOnASingleLine is already false in the Google
style, so it can be removed.  AllowShortFunctionsOnASingleLine should
not change between the -2 and -4 versions, so leave it at the Google
default style in both, which is 'All'.

The diff stats for these changes are:

./base/
Old:
640 insertions(+), 531 deletions(-)
New:
563 insertions(+), 808 deletions(-)

./debuggerd/
Old:
910 insertions(+), 886 deletions(-)
New:
991 insertions(+), 1023 deletions(-)

./adb/
Old:
2623 insertions(+), 2886 deletions(-)
New:
2655 insertions(+), 3103 deletions(-)

./libprocinfo/
Old:
2 insertions(+), 1 deletion(-)
New:
4 insertions(+), 18 deletions(-)

./fastboot/
Old:
618 insertions(+), 743 deletions(-)
New:
726 insertions(+), 882 deletions(-)

./init/
Old:
1755 insertions(+), 1866 deletions(-)
New:
1715 insertions(+), 1952 deletions(-)

Test: Above clang-format stats
Change-Id: I3f7b8ab0660c8394c5008ba95ea15e70dd22b55b
  • Loading branch information
Tom Cherry committed Mar 14, 2017
1 parent f31abeb commit 5b4eb23
Show file tree
Hide file tree
Showing 7 changed files with 5 additions and 75 deletions.
4 changes: 0 additions & 4 deletions .clang-format-2
Original file line number Diff line number Diff line change
@@ -1,8 +1,4 @@
BasedOnStyle: Google
AllowShortBlocksOnASingleLine: false
AllowShortFunctionsOnASingleLine: true

AccessModifierOffset: -1
ColumnLimit: 100
CommentPragmas: NOLINT:.*
DerivePointerAlignment: false
Expand Down
3 changes: 0 additions & 3 deletions .clang-format-4
Original file line number Diff line number Diff line change
@@ -1,7 +1,4 @@
BasedOnStyle: Google
AllowShortBlocksOnASingleLine: false
AllowShortFunctionsOnASingleLine: false

AccessModifierOffset: -2
ColumnLimit: 100
CommentPragmas: NOLINT:.*
Expand Down
13 changes: 0 additions & 13 deletions adb/.clang-format

This file was deleted.

1 change: 1 addition & 0 deletions adb/.clang-format
11 changes: 0 additions & 11 deletions base/.clang-format

This file was deleted.

1 change: 1 addition & 0 deletions base/.clang-format
15 changes: 0 additions & 15 deletions debuggerd/.clang-format

This file was deleted.

1 change: 1 addition & 0 deletions debuggerd/.clang-format
15 changes: 0 additions & 15 deletions fastboot/.clang-format

This file was deleted.

1 change: 1 addition & 0 deletions fastboot/.clang-format
14 changes: 0 additions & 14 deletions libprocinfo/.clang-format

This file was deleted.

1 change: 1 addition & 0 deletions libprocinfo/.clang-format

0 comments on commit 5b4eb23

Please sign in to comment.