Skip to content

Commit

Permalink
install clang-format automatically
Browse files Browse the repository at this point in the history
  • Loading branch information
dongyuwei committed Jul 10, 2019
1 parent eaee803 commit d900c6d
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 2 deletions.
1 change: 0 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -90,7 +90,6 @@ pinyin in, English out: <br/>

## 格式化代码

- `brew install clang-format`
- `sh format-code.sh`

## CI build
Expand Down
5 changes: 4 additions & 1 deletion format-code.sh
Original file line number Diff line number Diff line change
@@ -1,4 +1,7 @@
# brew install clang-format
if ! [ -x "$(command -v clang-format)" ]; then
echo 'Error: clang-format is not installed.'
brew install clang-format
fi

ls src/*.* | xargs clang-format -i
ls Tests/*.* | xargs clang-format -i

0 comments on commit d900c6d

Please sign in to comment.