Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/docker-android-sdk/android-30.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'tools/android-env.sh')
-rw-r--r--tools/android-env.sh44
1 files changed, 44 insertions, 0 deletions
diff --git a/tools/android-env.sh b/tools/android-env.sh
new file mode 100644
index 0000000..160aba6
--- /dev/null
+++ b/tools/android-env.sh
@@ -0,0 +1,44 @@
+#!/usr/bin/env bash
+
+export ANDROID_HOME=/opt/android-sdk-linux
+export ANDROID_SDK_ROOT=${ANDROID_HOME}
+export ANDROID_SDK_HOME=${ANDROID_HOME}
+export ANDROID_SDK=${ANDROID_HOME}
+
+export PATH=${PATH}:${ANDROID_HOME}/cmdline-tools/tools/bin:${ANDROID_HOME}/platform-tools:${ANDROID_HOME}/emulator:${ANDROID_HOME}/bin:
+
+function print_header() {
+ figlet SBB CFF FFS
+ figlet welcome to
+ figlet andep
+ echo ''
+ echo ''
+ echo ''
+}
+
+function help() {
+ figlet "usage:"
+ echo "update_sdk: Updates the SDK"
+ echo "andep: Installs one or more android Packets."
+ echo " -Example: anddep \"platforms;android-26\""
+ echo "help: Shows this help"
+ echo ''
+ echo ''
+ echo ''
+}
+
+function update_sdk() {
+ android-accept-licenses.sh "sdkmanager --update"
+}
+
+function andep() {
+ if [ -z ${1} ]; then
+ help
+ return 1
+ fi
+ android-accept-licenses.sh "sdkmanager ${1}"
+}
+
+export -f help
+export -f update_sdk
+export -f andep