File tree Expand file tree Collapse file tree
.github/workflows/scripts/android Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -37,18 +37,23 @@ install_package() {
3737 eval " $INSTALL_PACKAGE_COMMAND $1 "
3838}
3939
40+ command -v curl > /dev/null || install_package curl
41+
42+ # /usr/lib/jvm/java-17-openjdk-amd64
4043install_package java-17-openjdk-devel || install_package openjdk-17-jdk
4144
4245# download and install the Android SDK
4346mkdir ~ /android-sdk
44- cd ~ /android-sdk
47+ pushd ~ /android-sdk
4548export ANDROID_HOME=${PWD}
4649
4750curl --connect-timeout 30 --retry 3 --retry-delay 2 --retry-max-time 60 -fsSL -o commandlinetools.zip https://dl.google.com/android/repository/commandlinetools-linux-13114758_latest.zip
4851unzip commandlinetools.zip
49-
50- export PATH=${PATH} :${PWD} /cmdline-tools/bin
51- cd -
52+ mv cmdline-tools latest
53+ mkdir cmdline-tools
54+ mv latest cmdline-tools
55+ export PATH=${PATH} :${PWD} /cmdline-tools/latest/bin
56+ popd
5257
5358# install and start an Android emulator
5459sdkmanager --list_installed
You can’t perform that action at this time.
0 commit comments