View Source mix ecto.gen.view_migration (Ecto ViewMigrations v0.1.0)
Generates a view migration.
Uses the same configuration as Mix.Ecto.Gen.Migration.
examples
Examples
$ mix ecto.gen.view_migration posts_stats
$ mix ecto.gen.view_migration post_stats -r Custom.Repo
This will generate a migration file and a SQL file (in priv/repo/sql).
The SQL file should be edited to contain the code for your view.
command-line-options
Command line options
-r,--repo- the repo to generate migration for--migrations-path- the path to run the migrations from, defaults topriv/repo/migrations--sql-path- the path to store the sql files in, defaults topriv/repo/sql