mirror of
https://github.com/paperclipai/paperclip.git
synced 2026-12-05 06:03:51 +01:00
Replaces the legacy 853 MiB IDE-extension ACP bundle (agy_acp_server.par 1.5.2, localharness_external, and Python admission patching) and the separate 1.5.15 CLI pin with a single pinned agy 1.5.19 binary (1.5.19-4821414830800896, ~268 MiB on linux-x64) across ordinary turns, /swarm, sign-in, and model discovery. - Pin agy 1.5.19 across darwin-arm64, darwin-x64, linux-x64, and linux-arm64 and bump the Antigravity ACPX profile to v3 (regenerating TS and Rust profiles). - Add direct ACP runtime openAntigravityAcpRuntime for ordinary turns with OAuth and GEMINI_API_KEY auth, session/resume, plan mode, MCP bridge, setModel, and lineage retirement. - Stage file-backed OAuth tokens with AGY_CLI_FORCE_FILE_TOKEN_STORAGE=1, align --gemini-dir with agentHomeDirectory, and migrate login to agy acp --login. - Enable remote /swarm using --dangerously-skip-permissions and remove the input.remote refusal in antigravity-swarm.ts. - Regenerate the 25-model Antigravity catalog from agy 1.5.19. Tested with Runner unit/script/live suites, shared, UI, server, Rust cargo test, runner-e2e unit suites, and live E2E against real agy 1.5.19 on macOS and headless Linux Docker (--security-opt no-new-privileges). Co-Authored-By: Paperclip <noreply@paperclip.ing>
31 lines
1.8 KiB
JavaScript
31 lines
1.8 KiB
JavaScript
#!/usr/bin/env node
|
|
import { lstat } from "node:fs/promises";
|
|
import { resolve } from "node:path";
|
|
import { pathToFileURL } from "node:url";
|
|
import { antigravityProvisionerDestination } from "./antigravity-provisioner-layout.mjs";
|
|
import { antigravityDistribution, materializePinnedAntigravityDistribution, verifyAntigravityDistribution } from "./materialize-antigravity-distribution.mjs";
|
|
|
|
/** Explicit public installation; never invoked by an npm lifecycle hook. */
|
|
export async function provisionAntigravityRuntime(options = {}) {
|
|
const distribution = await antigravityDistribution(options.platform, options.architecture);
|
|
const destination = antigravityProvisionerDestination(options.moduleUrl ?? import.meta.url, distribution, options.home);
|
|
const installed = await lstat(destination).catch(error => {
|
|
if (error.code !== "ENOENT") throw error;
|
|
return null;
|
|
});
|
|
if (installed) {
|
|
if (!installed.isDirectory() || installed.isSymbolicLink()) throw new Error("Antigravity runtime assets must be a real directory");
|
|
await verifyAntigravityDistribution(destination, distribution);
|
|
} else {
|
|
await materializePinnedAntigravityDistribution({ destination, platform: distribution.platform, architecture: distribution.architecture, archivePath: options.archivePath });
|
|
}
|
|
return { ...distribution, destination, executable: resolve(destination, distribution.executable) };
|
|
}
|
|
|
|
if (process.argv[1] && pathToFileURL(resolve(process.argv[1])).href === import.meta.url) {
|
|
provisionAntigravityRuntime().then(result => {
|
|
console.log(`Verified Google Antigravity ${result.version} (${result.platform}-${result.architecture}), build ${result.build}`);
|
|
console.log(`Runtime: ${result.destination}. Run setup as the same OS user that runs Paperclip.`);
|
|
}).catch(error => { console.error(error.message); process.exitCode = 1; });
|
|
}
|