@oss-autopilot/core - v3.7.0
    Preparing search index...

    Function ensureGistPersistence

    Core module exports Re-exports all core functionality for convenient imports

    • Bootstrap helper for processes that may run in Gist persistence mode.

      Peeks at the state file to check if Gist mode is configured. If so and a valid token is provided, pre-sets the singleton via getStateManagerAsync so subsequent synchronous getStateManager calls return the Gist-backed instance. No-op when the state file is absent, unparseable, or not in Gist mode.

      Consolidates identical filesystem-peek + getStateManagerAsync logic that was duplicated between the CLI bootstrap (cli.ts) and MCP tool bootstrap (mcp-server/src/tools.ts) — #1000.

      Parameters

      • token: string | null

        GitHub token with gist scope, or null to skip activation

      Returns Promise<void>

      // CLI bootstrap
      await ensureGistPersistence(token);