PhilColumns.Seeder (glific_phil_columns v3.2.1)
Summary
Functions
Apply seeds in a directory to a repository with given strategy.
Gets all migrated versions.
Returns an array of tuples as the seed status of the given repo, without actually running any seeds.
Functions
@spec run(Ecto.Repo.t(), binary(), atom(), Keyword.t()) :: [integer()]
Apply seeds in a directory to a repository with given strategy.
A strategy must be given as an option.
Options
:all
- runs all available iftrue
:step
- runs the specific number of seeds:to
- runs all until the supplied version is reached:log
- the level to use for logging. Defaults to:info
. Can be any ofLogger.level/0
values orfalse
.
@spec seeded_versions(Ecto.Repo.t(), String.t()) :: list()
Gets all migrated versions.
This function ensures the migration table exists if no table has been defined yet.
Returns an array of tuples as the seed status of the given repo, without actually running any seeds.