forked from purerosefallen/YGOMobile
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathcircle.yml
76 lines (58 loc) · 3.5 KB
/
circle.yml
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
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
machine:
environment:
ANDROID_HOME: /usr/local/android-sdk-linux
QUALITY: 50
dependencies:
cache_directories:
- /usr/local/android-sdk-linux
- ~/.gradle
- ~/.android
override:
- sudo -E apt-get -yq update
- sudo -E apt-get -yq --no-install-suggests --no-install-recommends --force-yes install imagemagick
- echo y | android update sdk --no-ui --all --filter "platform-tools"
- echo y | android update sdk --no-ui --all --filter "tools"
- echo y | android update sdk --no-ui --all --filter "build-tools-26.0.2"
- echo y | android update sdk --no-ui --all --filter "android-26"
- echo y | android update sdk --no-ui --all --filter "extra-google-m2repository"
- echo y | android update sdk --no-ui --all --filter "extra-android-m2repository"
- cp -rf tools/licenses $ANDROID_HOME
- chmod 777 ./gradlew
- curl --retry 5 --connect-timeout 30 --location --remote-header-name --remote-name https://dl.google.com/android/repository/android-ndk-r15b-linux-x86_64.zip
- unzip -q android-ndk-r15b-linux-x86_64.zip
- curl --retry 5 --connect-timeout 30 --location --remote-header-name --remote-name https://github.com/purerosefallen/ygopro-222DIY/archive/local.zip
- unzip -q ygopro-222DIY-local.zip
- cp -rf ygopro-222DIY-local/ocgcore Classes
- curl --retry 5 --connect-timeout 30 --location --remote-header-name --remote-name https://github.com/Fluorohydride/ygopro-scripts/archive/master.zip
- unzip -q ygopro-scripts-master.zip
- mv -f ygopro-scripts-master script
- curl --retry 5 --connect-timeout 30 --location --remote-header-name --remote-name https://github.com/HuangYuNan/ygopro222-images/archive/master.zip
- unzip -q ygopro222-images-master.zip
- mv -f ygopro222-images-master pics
- curl --retry 5 --connect-timeout 30 --location --remote-header-name --remote-name https://github.com/purerosefallen/ygopro-7210srv/raw/master/strings.conf
- mv -f strings.conf mobile/assets/data/conf
- curl --retry 5 --connect-timeout 30 --location --remote-header-name --remote-name https://github.com/purerosefallen/ygopro-7210srv/raw/master/cards.cdb
- mv -f cards.cdb mobile/assets/data
- mkdir mobile/assets/data/expansions
- curl --retry 5 --connect-timeout 30 --location --remote-header-name --remote-name https://github.com/purerosefallen/ygopro-222DIY/archive/data.zip
- unzip -q ygopro-222DIY-data.zip
- cp -rf ygopro-222DIY-data/expansions/pics .
- cp -rf ygopro-222DIY-data/expansions/script .
- cp -rf ygopro-222DIY-data/expansions/*.cdb mobile/assets/data/expansions
- cp -rf ygopro-222DIY-data/expansions/strings.conf mobile/assets/data/expansions
- cp -rf ygopro-222DIY-data/lflist.conf mobile/assets/data/conf
- rm -rf pics/thumbnail
- rm -rf pics/*.db
- cd pics && ls *.jpg | xargs -I {} -P 4 convert -size 177x254! -quality $QUALITY {} {} && cd ..
- zip -q -r mobile/assets/data/pics.zip pics
- zip -q -r mobile/assets/data/scripts.zip script
- cp -rf tools/Application.mk libcore/jni
- cp -rf tools/*.png mobile/src/main/res/drawable
- cd libcore && ./../android-ndk-r15b/ndk-build -j8 && cd ..
test:
override:
- ./gradlew :libcore:assembleRelease :mobile:assembleMycardRelease
- find ~/.gradle -name *.lock -print | xargs -I {} -P 4 rm -rf {}
- find ~/.android -name *.lock -print | xargs -I {} -P 4 rm -rf {}
post:
- mv -f mobile/build/outputs/apk/mobile-mycard-armeabi-v7a-release.apk $CIRCLE_ARTIFACTS/ygomobile-$CIRCLE_BRANCH-$CIRCLE_BUILD_NUM.apk