warning for persistence
This commit is contained in:
@@ -194,6 +194,18 @@ form?.addEventListener("submit", async (e) => {
|
||||
noPrinting,
|
||||
};
|
||||
|
||||
const hasAndroid = platforms.some(p => p.startsWith('android-'));
|
||||
if (hasAndroid && enablePersistence) {
|
||||
if (!confirm(
|
||||
'⚠️ WARNING: Persistence is NOT supported on Android\n\n' +
|
||||
'The persistence setting will be ignored for Android builds.\n' +
|
||||
'Persistence is only supported on: Windows, Linux, and macOS\n\n' +
|
||||
'Continue with build anyway?'
|
||||
)) {
|
||||
return;
|
||||
}
|
||||
}
|
||||
|
||||
await startBuild(buildConfig);
|
||||
});
|
||||
|
||||
|
||||
@@ -269,9 +269,13 @@ export async function startBuildProcess(
|
||||
}
|
||||
|
||||
if (config.enablePersistence) {
|
||||
const persistenceFlag = "-X overlord-client/cmd/agent/config.DefaultPersistence=true";
|
||||
ldflags = ldflags ? `${ldflags} ${persistenceFlag}` : persistenceFlag;
|
||||
sendToStream({ type: "output", text: `Persistence enabled for ${platform}\n`, level: "info" });
|
||||
if (!platform.startsWith('android-')) {
|
||||
const persistenceFlag = "-X overlord-client/cmd/agent/config.DefaultPersistence=true";
|
||||
ldflags = ldflags ? `${ldflags} ${persistenceFlag}` : persistenceFlag;
|
||||
sendToStream({ type: "output", text: `Persistence enabled for ${platform}\n`, level: "info" });
|
||||
} else {
|
||||
sendToStream({ type: "output", text: `Persistence is not supported on ${platform}, skipping...\n`, level: "warning" });
|
||||
}
|
||||
}
|
||||
|
||||
if (buildAgentToken) {
|
||||
|
||||
Reference in New Issue
Block a user