mirror of
https://github.com/izzy2lost/docker-android.git
synced 2026-06-19 01:16:28 -07:00
Removed ATD and cleaned up the code because of ANDROID_HOME
This commit is contained in:
+4
-4
@@ -98,12 +98,12 @@ def prepare_avd(device: str, avd_name: str, dp_size: str):
|
||||
profile_dst_path = os.path.join(ROOT, '.android', 'devices.xml')
|
||||
if 'samsung' in device.lower():
|
||||
# profile file name = skin name
|
||||
profile_src_path = os.path.join(ROOT, 'devices', 'profiles', '{profile}.xml'.format(profile=skin_name))
|
||||
profile_src_path = os.path.join(ANDROID_HOME, 'devices', 'profiles', '{profile}.xml'.format(profile=skin_name))
|
||||
logger.info('Hardware profile resource path: {rsc}'.format(rsc=profile_src_path))
|
||||
logger.info('Hardware profile destination path: {dst}'.format(dst=profile_dst_path))
|
||||
symlink_force(profile_src_path, profile_dst_path)
|
||||
|
||||
avd_path = '/'.join([ANDROID_HOME, 'android_emulator'])
|
||||
avd_path = '/'.join([ROOT, 'android_emulator'])
|
||||
creation_cmd = 'avdmanager create avd -f -n {name} -b {img_type}/{sys_img} -k "system-images;android-{api_lvl};' \
|
||||
'{img_type};{sys_img}" -d {device} -p {path}'.format(name=avd_name, img_type=IMG_TYPE,
|
||||
sys_img=SYS_IMG,
|
||||
@@ -226,10 +226,10 @@ def run():
|
||||
|
||||
if is_first_run:
|
||||
logger.info('Emulator was not previously initialized. Preparing a new one...')
|
||||
cmd = 'emulator/emulator @{name} -gpu swiftshader_indirect -accel on -wipe-data -writable-system -verbose {custom_args}'.format(name=avd_name, custom_args=custom_args)
|
||||
cmd = 'emulator @{name} -gpu swiftshader_indirect -accel on -wipe-data -writable-system -verbose {custom_args}'.format(name=avd_name, custom_args=custom_args)
|
||||
else:
|
||||
logger.info('Using previously initialized AVD...')
|
||||
cmd = 'emulator/emulator @{name} -gpu swiftshader_indirect -accel on -verbose -writable-system {custom_args}'.format(name=avd_name, custom_args=custom_args)
|
||||
cmd = 'emulator @{name} -gpu swiftshader_indirect -accel on -verbose -writable-system {custom_args}'.format(name=avd_name, custom_args=custom_args)
|
||||
|
||||
appium = convert_str_to_bool(str(os.getenv('APPIUM', False)))
|
||||
if appium:
|
||||
|
||||
@@ -1,6 +0,0 @@
|
||||
#!/bin/bash
|
||||
|
||||
if [ "$ATD" = true ]; then
|
||||
echo "Starting ATD..."
|
||||
java -jar /root/RemoteAppiumManager.jar -DPort=4567
|
||||
fi
|
||||
Reference in New Issue
Block a user