android-emulator-runner icon indicating copy to clipboard operation
android-emulator-runner copied to clipboard

Only overwrite ANDROID_AVD_HOME if not set

Open tmpsantos opened this issue 1 year ago • 2 comments

The path might point to a different path than what android-emulator-runner expects, like when XDG_CONFIG_HOME is set.

tmpsantos avatar Sep 27 '24 16:09 tmpsantos

What I'm seeing here is because XDG_CONFIG_HOME is set, it is being used as base path for where the emulator is being created and it breaks when the script tries to append the hardware configuration because it is hardcoded to the home directory.

tmpsantos avatar Sep 27 '24 16:09 tmpsantos

@ychescale9 this (XDG_CONFIG_HOME) is probably the root cause of what I saw with the weird pathing issues for AVD home - since XDG_CONFIG_HOME is $HOME/.config and that was the root path the avdmanager was installing in to on Ubuntu 24

In #410 I specify even more variables, which ... works, but this solution might be more respectful of the system, and setting the other AVD related env vars (ANDROID_EMULATOR_HOME, ANDROID_USER_HOME) based on the existing ANDROID_AVD_HOME might be a better idea

mikehardy avatar Oct 11 '24 01:10 mikehardy

@mikehardy @ychescale9 a bit late here, but thank you for working on this!

tmpsantos avatar Mar 05 '25 14:03 tmpsantos