mix aurora_meter.install (Aurora Meter v0.3.0)

View Source

Installs Aurora Meter into a Phoenix (or plain Ecto) application in one step, powered by Igniter:

mix igniter.install aurora_meter
# or, once the dep is in mix.exs:
mix aurora_meter.install --repo MyApp.Repo

It will

  • add config :aurora_meter, repo: ..., pubsub: ..., plans: ... to config/config.exs
  • add AuroraMeter to your application's children, after the repo and PubSub
  • create a MyApp.Plans module with a :free and a :pro plan (never overwrites one you have)
  • generate the migration that delegates to AuroraMeter.Migration

Options: --repo, --pubsub, --plans (module names; all inferred when omitted).

Without Igniter available the task falls back to generating the migration and printing the remaining steps.