We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 6b5cee7 commit 1a34456Copy full SHA for 1a34456
1 file changed
docker/owlbot/java/bin/format_source.sh
@@ -17,4 +17,22 @@ set -e
17
18
# Find all the java files relative to the current directory and format them
19
# using google-java-format
20
-find . -name '*.java' | xargs java -jar /owlbot/google-java-format.jar --replace
+list="$(find . -name '*.java' )"
21
+tmpfile=$(mktemp)
22
+
23
+for file in $list;
24
+do
25
+ if [[ "$file" =~ ".*/samples/snippets/src/main/java/com/example/firestore/Quickstart.java" ]];
26
+ then
27
+ echo "File skipped formatting: $file"
28
+ elif [[ "$file" =~ ".*/samples/snippets/src/main/java/com/example/spanner/.*.java" ]];
29
30
31
+ else
32
+ echo $file >> $tmpfile
33
+ fi
34
+done
35
36
+cat $tmpfile | xargs java -jar /owlbot/google-java-format.jar --replace
37
38
+rm $tmpfile
0 commit comments