mirror of
https://github.com/microsoft/mscclpp.git
synced 2026-05-11 17:00:22 +00:00
Use clang-format-12
This commit is contained in:
@@ -80,6 +80,7 @@ IncludeCategories:
|
||||
IncludeIsMainRegex: '(Test)?$'
|
||||
IncludeIsMainSourceRegex: ''
|
||||
IndentCaseLabels: false
|
||||
IndentExternBlock: NoIndent
|
||||
IndentGotoLabels: true
|
||||
IndentPPDirectives: None
|
||||
IndentWidth: 2
|
||||
|
||||
2
.github/workflows/cpplint.yml
vendored
2
.github/workflows/cpplint.yml
vendored
@@ -20,7 +20,7 @@ jobs:
|
||||
uses: actions/checkout@v3
|
||||
|
||||
- name: Install ClangFormat
|
||||
run: sudo apt-get install -y clang-format
|
||||
run: sudo apt-get install -y clang-format-12
|
||||
|
||||
- name: Run cpplint
|
||||
run: make cpplint
|
||||
|
||||
6
Makefile
6
Makefile
@@ -147,14 +147,14 @@ lib: $(LIBOBJTARGETS) $(INCTARGETS) $(LIBTARGET)
|
||||
tests: $(TESTSBINS)
|
||||
|
||||
cpplint:
|
||||
clang-format -style=file --verbose --Werror --dry-run $(CPPSOURCES)
|
||||
clang-format-12 -style=file --verbose --Werror --dry-run $(CPPSOURCES)
|
||||
|
||||
cpplint-autofix:
|
||||
clang-format -style=file --verbose --Werror -i $(CPPSOURCES)
|
||||
clang-format-12 -style=file --verbose --Werror -i $(CPPSOURCES)
|
||||
|
||||
# Run cpplint on a single file, example: make cpplint-file INPUTFILE=src/bootstrap/bootstrap.cc
|
||||
cpplint-file-autofix:
|
||||
clang-format -style=file --verbose --Werror -i $(INPUTFILE)
|
||||
clang-format-12 -style=file --verbose --Werror -i $(INPUTFILE)
|
||||
|
||||
# Compile libobjs
|
||||
$(BUILDDIR)/$(OBJDIR)/%.o: %.cc $(HEADERS)
|
||||
|
||||
Reference in New Issue
Block a user