-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathharddiff.sh
executable file
·54 lines (48 loc) · 1.21 KB
/
harddiff.sh
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
#!/bin/bash
set -x
val=$(repo sync . | echo $?)
if [ $val != 0 ]; then
echo could not repo sync local directory, bailing.
fi
rm -rf /tmp/robo
mkdir -p /tmp/robo || true
pushd /tmp/robo
git clone -b google --single-branch https://github.com/robolectric/robolectric.git
#git checkout google
popd
echo building patch
# waiting on clean up the ttf/icu data -- hence nativeruntime resources are ignored.
# we also need
diff -Naur . /tmp/robo/robolectric \
-x '*.bp' \
-x '*.md' \
-x 'harddiff.sh' \
-x 'METADATA' \
-x 'MODULE_LICENSE_MIT' \
-x 'NOTICE' \
-x 'OWNERS' \
-x 'soong*' \
-x '.git*' \
-x 'buildSrc' \
-x 'gradle' \
-x '*.gradle' \
-x 'sdks.txt' \
-x '*.ttf' \
-x '*.utf' \
-x '*.otf' \
-x '*.ttc' \
-x 'fonts.xml' \
-x '*.dat' \
-x 'lint-baseline.xml' \
-x 'robo-manifest.xml' \
-x 'AndroidManifest.xml' \
-x 'README' \
-x 'robolectric.properties' \
> /tmp/robo/patch
echo applying patch
patch -p1 < /tmp/robo/patch
echo patch applied
# How to auto revert an existing CL from upstream on top of the diff
# One per CL please.
# echo reverting upstream CL due to ...
# git diff 162eaf30e754fdc3322b2c6b0df6576b4555e650 162eaf30e754fdc3322b2c6b0df6576b4555e650^ | patch -p1