persistent-migration-0.1.0: Manual migrations for the persistent library

MaintainerBrandon Chinn <brandonchinn178@gmail.com>
Stabilityexperimental
Portabilityportable
Safe HaskellNone
LanguageHaskell2010

Database.Persist.Migration.Core

Description

Defines a migration framework for the persistent library.

Synopsis

Documentation

newtype MigrateSettings Source #

Settings to customize migration steps.

Constructors

MigrateSettings 

Fields

defaultSettings :: MigrateSettings Source #

Default migration settings.

validateMigration :: Migration -> Either String () Source #

Validate the given migration.

runMigration :: MonadIO m => MigrateBackend -> MigrateSettings -> Migration -> SqlPersistT m () Source #

Run the given migration. After successful completion, saves the migration to the database.

getMigration :: MonadIO m => MigrateBackend -> MigrateSettings -> Migration -> SqlPersistT m [MigrateSql] Source #

Get the SQL queries for the given migration.