Add option to specify AVD heap size (#245)

This commit is contained in:
Tim Malseed
2022-04-26 23:36:59 +10:00
committed by GitHub
parent 689ee971a8
commit cc3dd8cbef
6 changed files with 21 additions and 2 deletions
+5
View File
@@ -13,6 +13,7 @@ export async function launchEmulator(
profile: string,
cores: string,
ramSize: string,
heapSize: string,
sdcardPathOrSize: string,
diskSize: string,
avdName: string,
@@ -44,6 +45,10 @@ export async function launchEmulator(
await exec.exec(`sh -c \\"printf 'hw.ramSize=${ramSize}\n' >> ${process.env.ANDROID_AVD_HOME}/"${avdName}".avd"/config.ini`);
}
if (heapSize) {
await exec.exec(`sh -c \\"printf 'hw.heapSize=${heapSize}\n' >> ${process.env.ANDROID_AVD_HOME}/"${avdName}".avd"/config.ini`);
}
if (enableHardwareKeyboard) {
await exec.exec(`sh -c \\"printf 'hw.keyboard=yes\n' >> ${process.env.ANDROID_AVD_HOME}/"${avdName}".avd"/config.ini`);
}