# `mix ex_athena.install`
[🔗](https://github.com/udin-io/ex_athena/blob/v0.7.1/lib/mix/tasks/ex_athena.install.ex#L2)

Installs ExAthena into your project.

Run once after adding `{:ex_athena, "~> 0.4"}` to `mix.exs`, or via Igniter:

    mix igniter.install ex_athena
    mix ex_athena.install

## What it does

  * Writes a `config :ex_athena, default_provider: :ollama` default to
    `config/config.exs` (only if no default is already configured).
  * Writes sensible per-provider defaults for Ollama (base URL pointing at
    `http://localhost:11434`), OpenAI-compatible (`https://api.openai.com/v1`),
    and Claude (picks up `ANTHROPIC_API_KEY` from env).
  * Scaffolds `.exathena/.gitignore` so v0.4 runtime artifacts (session
    JSONL logs, file-history snapshots, worktree cache) aren't
    accidentally committed.
  * Does NOT write API keys inline — the installer uses
    `{:system, "VAR"}` tuples so secrets stay in the environment.

Idempotent: re-running preserves whatever you've already set.

## Upgrading

From an older version of ex_athena, run:

    mix igniter.upgrade ex_athena

which routes through `mix ex_athena.upgrade` and applies any
version-specific migrations (e.g. notices about the v0.4
tool-result-split breaking change).

---

*Consult [api-reference.md](api-reference.md) for complete listing*
