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>
This commit is contained in:
Daniel Verkamp 2019-10-23 10:55:21 -07:00 committed by Commit Bot
parent ff783c3b7d
commit 3530f2a2bb

View file

@ -26,4 +26,4 @@ cd "$(dirname "${BASH_SOURCE[0]}")"
# Jump up to root directory of crosvm repo. # Jump up to root directory of crosvm repo.
cd .. cd ..
find . -name '*.rs' -print0 | xargs -0 rustfmt "$@" -- find . -name '*.rs' -print0 | grep -vz '^./target/' | xargs -0 rustfmt "$@" --