-
Notifications
You must be signed in to change notification settings - Fork 8
Expand file tree
/
Copy pathinitialize-android.sh
More file actions
24 lines (18 loc) · 853 Bytes
/
initialize-android.sh
File metadata and controls
24 lines (18 loc) · 853 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
#!/bin/bash
# raise an error if any command fails!
set -e
INITIALIZATION_FILE="$ANDROID_HOME/.initialized-dependencies"
if [ ! -e ${INITIALIZATION_FILE} ]; then
# fetch and initialize $ANDROID_HOME
download-android
# Use the latest android sdk tools
echo y | android update sdk --no-ui --filter platform-tools > /dev/null
echo y | android update sdk --no-ui --filter tools > /dev/null
# The BuildTools version used by your project
echo y | android update sdk --no-ui --filter build-tools-20.0.0 --all > /dev/null
# The SDK version used to compile your project
echo y | android update sdk --no-ui --filter android-19 > /dev/null
# Specify at least one system image if you want to run emulator tests
echo y | android update sdk --no-ui --filter sys-img-armeabi-v7a-android-19 --all > /dev/null
touch ${INITIALIZATION_FILE}
fi