@@ -66,7 +66,7 @@ let
6666 }
6767:}
6868
69−Now that we have a couple migrations we can chain them together into an `AlignedList`.
69+Now that we have a couple migrations we can chain them together into a `Path`.
7070
7171>>> let migrations = makeUsers :>> makeEmails :>> Done
7272
@@ -190,34 +190,34 @@ data Migration p schemas0 schemas1 = Migration
190190
191191{- |
192192A `Migratory` @p@ is a `Category` for which one can execute or rewind
193−an `AlignedList` of `Migration`s over @p@. This includes the category of pure
193+a `Path` of `Migration`s over @p@. This includes the category of pure
194194SQL `Definition`s and the category of impure `Terminally` `PQ` `IO` actions.
195195-}
196196class Category p => Migratory p where
197197
198198 {- |
199− Run an `AlignedList` of `Migration`s.
199+ Run a `Path` of `Migration`s.
200200 Create the `MigrationsTable` as @public.schema_migrations@ if it does not already exist.
201201 In one transaction, for each each `Migration` query to see if the `Migration` has been executed;
202202 if not, `up` the `Migration` and insert its `name` in the `MigrationsTable`.
203203 -}
204204 migrateUp
205− :: AlignedList (Migration p) schemas0 schemas1
205+ :: Path (Migration p) schemas0 schemas1
206206 -> PQ schemas0 schemas1 IO ()
207207
208208 {- |
209− Rewind an `AlignedList` of `Migration`s.
209+ Rewind a `Path` of `Migration`s.
210210 Create the `MigrationsTable` as @public.schema_migrations@ if it does not already exist.
211211 In one transaction, for each each `Migration` query to see if the `Migration` has been executed;
212212 if so, `down` the `Migration` and delete its `name` in the `MigrationsTable`.
213213 -}
214214 migrateDown
215− :: AlignedList (Migration p) schemas0 schemas1
215+ :: Path (Migration p) schemas0 schemas1
216216 -> PQ schemas1 schemas0 IO ()
217217
218218instance Migratory Definition where
219− migrateUp = migrateUp . mapAligned pureMigration
220− migrateDown = migrateDown . mapAligned pureMigration
219+ migrateUp = migrateUp . cmap pureMigration
220+ migrateDown = migrateDown . cmap pureMigration
221221
222222{- | `Terminally` turns an indexed monad transformer and the monad it transforms
223223into a category by restricting the return type to @()@ and permuting the type variables.
@@ -266,7 +266,7 @@ instance Migratory (Terminally PQ IO) where
266266 where
267267
268268 upMigrations
269− :: AlignedList (Migration (Terminally PQ IO)) schemas0 schemas1
269+ :: Path (Migration (Terminally PQ IO)) schemas0 schemas1
270270 -> PQ MigrationsSchemas MigrationsSchemas IO ()
271271 upMigrations = \case
272272 Done -> return ()
@@ -295,7 +295,7 @@ instance Migratory (Terminally PQ IO) where
295295 where
296296
297297 downMigrations
298− :: AlignedList (Migration (Terminally PQ IO)) schemas0 schemas1
298+ :: Path (Migration (Terminally PQ IO)) schemas0 schemas1
299299 -> PQ MigrationsSchemas MigrationsSchemas IO ()
300300 downMigrations = \case
301301 Done -> return ()
@@ -382,7 +382,7 @@ defaultMain
382382 :: Migratory p
383383 => ByteString
384384 -- ^ connection string
385− -> AlignedList (Migration p) db0 db1
385+ -> Path (Migration p) db0 db1
386386 -- ^ migrations
387387 -> IO ()
388388defaultMain connectTo migrations = do
@@ -403,7 +403,7 @@ defaultMain connectTo migrations = do
403403 migrateStatus :: PQ schema schema IO ()
404404 migrateStatus = unsafePQ $ do
405405 runNames <- getRunMigrationNames
406− let names = extractList name migrations
406+ let names = ctoList name migrations
407407 unrunNames = names \\ runNames
408408 liftIO $ displayRunned runNames >> displayUnrunned unrunNames
409409