Android Studio complains that it can't launch the emulator due to a lack of space.
The folder ~/.android
contains (among others) the virtual devices and is therefore quite big. I would like to move it to another partition where there is more space.
There are plenty of descriptions out there explaing how to move this directory: just move the directory and set the environment variable ANDROID_SDK_HOME
.
The problem is, all of these explanations are for Windows.
I have moved the directory and tried setting the environment variable in ~/.bashrc
(which is sourced by ~/.bash_profile
) and ~/.profile
while Android Studio was not running
export ANDROID_SDK_HOME='/mnt/data/accessories/android'
and in ~/.pam_environment
(as recommended here)
ANDROID_SDK_HOME=/home/user/data/accessories/android
Android Studio opens happily after the time it needs, creates a new ~/.android
directory without saying a word and does not find the virtual devices.
It does not matter whether I am running android-studio from the command line or via an i3 shortcut.
I have rebooted the entire system before launching Android Studio - just in case.
I am using Arch Linux and Android Studio 3.2.
How do I move ~/.android
on Linux?