# `mix ecto.gen.repo`
[🔗](https://github.com/elixir-ecto/ecto/blob/v3.13.6/lib/mix/tasks/ecto.gen.repo.ex#L1)

Generates a new repository.

The repository will be placed in the `lib` directory.

## Examples

    $ mix ecto.gen.repo -r Custom.Repo

This generator will automatically open the config/config.exs
after generation if you have `ECTO_EDITOR` set in your environment
variable.

## Command line options

  * `-r`, `--repo` - the repo to generate

---

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