aboutsummaryrefslogtreecommitdiffhomepage
path: root/tools/dockerfile/grpc_clang_format
diff options
context:
space:
mode:
authorGravatar Craig Tiller <ctiller@google.com>2017-11-03 09:09:36 -0700
committerGravatar Craig Tiller <ctiller@google.com>2017-11-03 09:09:36 -0700
commitbaa14a975ef92ee6fb301f0e684f56f18f2c55a7 (patch)
tree9a6cb2df58fe175e8abfccf2cbd40349726e46f3 /tools/dockerfile/grpc_clang_format
parentef68fe7239a89095f1eaa89c1dd28b2b7be2a3c7 (diff)
Update clang-format to 5.0
Diffstat (limited to 'tools/dockerfile/grpc_clang_format')
-rw-r--r--tools/dockerfile/grpc_clang_format/Dockerfile10
-rwxr-xr-xtools/dockerfile/grpc_clang_format/clang_format_all_the_things.sh2
2 files changed, 6 insertions, 6 deletions
diff --git a/tools/dockerfile/grpc_clang_format/Dockerfile b/tools/dockerfile/grpc_clang_format/Dockerfile
index dff07feeb6..de58a8b2f2 100644
--- a/tools/dockerfile/grpc_clang_format/Dockerfile
+++ b/tools/dockerfile/grpc_clang_format/Dockerfile
@@ -14,11 +14,11 @@
FROM debian:jessie
-RUN apt-get update && apt-get -y install wget
-RUN echo "deb http://llvm.org/apt/jessie/ llvm-toolchain-jessie-3.8 main" >> /etc/apt/sources.list
-RUN echo "deb-src http://llvm.org/apt/jessie/ llvm-toolchain-jessie-3.8 main" >> /etc/apt/sources.list
-RUN wget -O - http://llvm.org/apt/llvm-snapshot.gpg.key | apt-key add -
-RUN apt-get update && apt-get -y install clang-format-3.8
+RUN apt-get update && apt-get -y install wget xz-utils
+RUN wget http://releases.llvm.org/5.0.0/clang+llvm-5.0.0-linux-x86_64-ubuntu14.04.tar.xz
+RUN tar xf clang+llvm-5.0.0-linux-x86_64-ubuntu14.04.tar.xz
+ENV PATH=clang+llvm-5.0.0-linux-x86_64-ubuntu14.04/bin:$PATH
+ENV CLANG_FORMAT=clang-format
ADD clang_format_all_the_things.sh /
CMD ["echo 'Run with tools/distrib/clang_format_code.sh'"]
diff --git a/tools/dockerfile/grpc_clang_format/clang_format_all_the_things.sh b/tools/dockerfile/grpc_clang_format/clang_format_all_the_things.sh
index c471344157..6e7be7485c 100755
--- a/tools/dockerfile/grpc_clang_format/clang_format_all_the_things.sh
+++ b/tools/dockerfile/grpc_clang_format/clang_format_all_the_things.sh
@@ -22,7 +22,7 @@ DIRS="src/core/lib src/core/tsi src/core/ext src/cpp test/core test/cpp include
GLOB="*.h *.c *.cc"
# clang format command
-CLANG_FORMAT=clang-format-3.8
+CLANG_FORMAT=${CLANG_FORMAT:-clang-format-5.0}
files=
for dir in $DIRS