summary refs log tree commit diff
diff options
context:
space:
mode:
authorDaniel Verkamp <dverkamp@chromium.org>2019-10-23 10:55:21 -0700
committerCommit Bot <commit-bot@chromium.org>2019-10-25 23:54:14 +0000
commit3530f2a2bb05f8ccf45d2fa452c9f9f4de547876 (patch)
tree99f05026af6180840bdab8b0f4aac7fb9754cdb6
parentff783c3b7d44423ace8819a4cbc2c02ceb4e7fc9 (diff)
downloadcrosvm-3530f2a2bb05f8ccf45d2fa452c9f9f4de547876.tar
crosvm-3530f2a2bb05f8ccf45d2fa452c9f9f4de547876.tar.gz
crosvm-3530f2a2bb05f8ccf45d2fa452c9f9f4de547876.tar.bz2
crosvm-3530f2a2bb05f8ccf45d2fa452c9f9f4de547876.tar.lz
crosvm-3530f2a2bb05f8ccf45d2fa452c9f9f4de547876.tar.xz
crosvm-3530f2a2bb05f8ccf45d2fa452c9f9f4de547876.tar.zst
crosvm-3530f2a2bb05f8ccf45d2fa452c9f9f4de547876.zip
bin/fmt: ignore generated files in target dir
Don't check formatting for *.rs files generated by the protobuf code
generator.

BUG=None
TEST=bin/fmt --check
TEST=docker/wrapped_smoke_test.sh

Change-Id: I74af762d2758e6106a855f27214646b51f640b11
Signed-off-by: Daniel Verkamp <dverkamp@chromium.org>
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/crosvm/+/1876838
Tested-by: kokoro <noreply+kokoro@google.com>
Reviewed-by: Stephen Barber <smbarber@chromium.org>
-rwxr-xr-xbin/fmt2
1 files changed, 1 insertions, 1 deletions
diff --git a/bin/fmt b/bin/fmt
index 69d1140..7221347 100755
--- a/bin/fmt
+++ b/bin/fmt
@@ -26,4 +26,4 @@ cd "$(dirname "${BASH_SOURCE[0]}")"
 # Jump up to root directory of crosvm repo.
 cd ..
 
-find . -name '*.rs' -print0 | xargs -0 rustfmt "$@" --
+find . -name '*.rs' -print0 | grep -vz '^./target/' | xargs -0 rustfmt "$@" --