summaryrefslogtreecommitdiff
path: root/PREUPLOAD.cfg
diff options
context:
space:
mode:
authorThiƩbaud Weksteen <tweek@google.com>2020-06-23 15:40:10 +0200
committerThiƩbaud Weksteen <tweek@google.com>2020-06-23 15:50:23 +0200
commit4ca7152102a69d9af4b785cc5dbd9f2c2e04f40f (patch)
tree90243c9f2f5931cd243798904602525c0785d071 /PREUPLOAD.cfg
parent442727c6e81d60c25bdbee1dab361d3e273aebc7 (diff)
downloadsecurity-4ca7152102a69d9af4b785cc5dbd9f2c2e04f40f.tar.gz
Enable rustfmt for system/security
The rustfmt configuration is linked to the default from build/soong/scripts. This is similar to how clang-format is setup for system/core. Test: Added a commit with a bogus lib.rs and run repo upload. An error is returned by the rusfmt hook. Bug: 157146658 Change-Id: If346bdd73c9cdd84c3cd98ed00b95ed9d790aa4f
Diffstat (limited to 'PREUPLOAD.cfg')
-rw-r--r--PREUPLOAD.cfg2
1 files changed, 2 insertions, 0 deletions
diff --git a/PREUPLOAD.cfg b/PREUPLOAD.cfg
index dcf92be1..68df61f1 100644
--- a/PREUPLOAD.cfg
+++ b/PREUPLOAD.cfg
@@ -1,8 +1,10 @@
[Builtin Hooks]
clang_format = true
+rustfmt = true
[Builtin Hooks Options]
clang_format = --commit ${PREUPLOAD_COMMIT} --style file --extensions c,h,cc,cpp
+rustfmt = --check --config-path=rustfmt.toml ${PREUPLOAD_FILES}
[Hook Scripts]
aosp_hook = ${REPO_ROOT}/frameworks/base/tools/aosp/aosp_sha.sh ${PREUPLOAD_COMMIT} "."