feat(installer): offer CodeGraph Pro beta signup after install and upgrade (#1297)

One-time, strictly opt-in prompt at the end of codegraph install and
codegraph upgrade to join the CodeGraph Pro beta waitlist (same list as
the getcodegraph.com homepage form). Nothing is sent unless the user
answers yes AND enters an email; either answer is recorded machine-wide
so no later install or upgrade re-asks, and --yes / non-interactive / CI
runs never see the prompt.

Co-authored-by: Claude Fable 5 <noreply@anthropic.com>
This commit is contained in:
Colby Mchenry
2026-07-15 19:11:06 -05:00
committed by GitHub
co-authored by Claude Fable 5
parent 2b0b4b587e
commit a66683d3eb
8 changed files with 430 additions and 0 deletions
+12
View File
@@ -29,6 +29,7 @@ import { watchDisabledReason } from '../sync/watch-policy';
import { isGitRepo, isSyncHookInstalled, installGitSyncHook } from '../sync/git-hooks';
import { getCodeGraphDir, codeGraphDirName } from '../directory';
import { getTelemetry, TELEMETRY_DOCS } from '../telemetry';
import { maybeOfferBetaSignup } from './beta-signup';
// Backwards-compat: keep these named exports — downstream code may
// import them. The shim in `config-writer.ts` continues to re-export
@@ -266,6 +267,17 @@ export async function runInstallerWithOptions(opts: RunInstallerOptions): Promis
});
}
// Step 5½: CodeGraph Pro beta opt-in — the same waitlist as the
// getcodegraph.com homepage form, offered once per machine at the end of a
// successful install (and after `codegraph upgrade` — the shared gate in
// maybeOfferBetaSignup means whichever asks first is the ONLY ask ever).
// Strictly opt-in (user answers yes AND types an email), never shown under
// --yes, and any yes/no answer is stored so nothing re-asks. Cancel or a
// failed submit stores nothing, so a later install/upgrade may offer again.
if (!useDefaults && installedIds.length > 0) {
await maybeOfferBetaSignup({ source: 'cli-install' });
}
// Step 6: install wires up agents only — it deliberately does NOT index.
// Building the per-project graph is the user's explicit `codegraph init`
// (or `index`), so they choose what gets indexed and when, and we never