summaryrefslogtreecommitdiff
path: root/tools/format.py
diff options
context:
space:
mode:
authorYoshiya Hinosawa <stibium121@gmail.com>2018-08-17 12:44:55 +0900
committerRyan Dahl <ry@tinyclouds.org>2018-08-17 12:58:58 -0400
commit67d89ff692a88ae42145043eac1a5c58413ae110 (patch)
treef887cab56cf684ba67f40293f554c0caf41af060 /tools/format.py
parent565a21eb0eee61048f6f770bfb24a03131fbc958 (diff)
chore: download clang-format from google storage
Diffstat (limited to 'tools/format.py')
-rwxr-xr-xtools/format.py6
1 files changed, 3 insertions, 3 deletions
diff --git a/tools/format.py b/tools/format.py
index 51bf2c1fb..85dbf2d4d 100755
--- a/tools/format.py
+++ b/tools/format.py
@@ -1,6 +1,6 @@
#!/usr/bin/env python
import os
-from third_party import third_party_path, fix_symlinks, google_env
+from third_party import third_party_path, fix_symlinks, google_env, clang_format_path
from util import root_path, run, find_exts
fix_symlinks()
@@ -12,8 +12,8 @@ rustfmt_config = os.path.join(tools_path, "rustfmt.toml")
os.chdir(root_path)
-# TODO(ry) Use third_party/depot_tools/clang-format.
-run(["clang-format", "-i", "-style", "Google"] + find_exts("src", ".cc", ".h"))
+run([clang_format_path, "-i", "-style", "Google"] +
+ find_exts("src", ".cc", ".h"))
for fn in ["BUILD.gn", ".gn"] + find_exts("build_extra", ".gn", ".gni"):
run(["third_party/depot_tools/gn", "format", fn], env=google_env())