> ## Documentation Index
> Fetch the complete documentation index at: https://docs.edgespark.dev/llms.txt
> Use this file to discover all available pages before exploring further.

# Gemini CLI and EdgeSpark

> Set up Gemini CLI to work with EdgeSpark — install the extension, generate GEMINI.md, and use pre-built tools for EdgeSpark workflows.

Gemini CLI is a first-class supported agent for EdgeSpark. The EdgeSpark Gemini workflow uses `GEMINI.md` as the project instructions file together with the dedicated Gemini CLI extension.

<Steps>
  <Step title="Install the EdgeSpark CLI">
    ```bash theme={null}
    npm install -g @edgespark/cli
    edgespark login
    ```

    This installs the CLI globally and authenticates your account. Your credentials are stored locally and reused for all subsequent commands.
  </Step>

  <Step title="Install the EdgeSpark Gemini CLI extension">
    ```bash theme={null}
    gemini extensions install https://github.com/edgesparkhq/gemini-extensions
    ```

    This is the current public Gemini CLI onboarding flow exposed by EdgeSpark.
  </Step>

  <Step title="Initialize your project">
    Pass `--agent gemini` to generate `GEMINI.md`:

    ```bash theme={null}
    edgespark init my-app --agent gemini
    cd my-app
    ```

    The scaffold writes `GEMINI.md` at the project root so Gemini CLI sessions have a dedicated EdgeSpark instructions file.
  </Step>

  <Step title="Start an EdgeSpark task">
    In Gemini CLI, use the EdgeSpark task-entry command:

    ```text theme={null}
    /edgespark:building-edgespark-apps
    ```
  </Step>
</Steps>

## Extending GEMINI.md

Add project-specific rules below the generated content:

```markdown theme={null}
<!-- Generated content above — do not edit -->

## Project-specific rules

- The `posts` table is soft-deleted — always filter `WHERE deleted_at IS NULL`
- Route `/api/admin/*` requires `user.role === 'admin'` checked after platform auth
```

Gemini follows these additions with the same priority as the generated content. See [AGENTS.md reference](/agents/agents-md) for the full format.

## See also

<Columns cols={2}>
  <Card title="AGENTS.md reference" icon="file-lines" href="/agents/agents-md">
    Full reference for the agent instructions file — what it contains and how to extend it.
  </Card>

  <Card title="Declarative workflow" icon="database" href="/agents/declarative-workflow">
    How Gemini CLI pulls schema and writes code against generated types.
  </Card>

  <Card title="Deploy and test loop" icon="rotate" href="/agents/deploy-and-test">
    The full autonomous deploy and test workflow for any agent.
  </Card>

  <Card title="Supported agents" icon="robot" href="/agents/supported-agents">
    All supported AI agents and their setup pages.
  </Card>
</Columns>
