You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
piq9117 0e69005956 config (#32) 8 months ago
app firsties 1 year ago
nix update pinned nix rev (#26) 10 months ago
src config (#32) 8 months ago
test naming convention (#28) 10 months ago
.gitignore logging (#1) 1 year ago
.stylish-haskell.yaml firsties 1 year ago firsties 1 year ago
LICENSE license and readme 1 year ago
Makefile firsties 1 year ago readme (#20) 11 months ago
Setup.hs firsties 1 year ago
default.nix didn't need set (#15) 11 months ago
migratum.cabal migratumInfo (#23) 10 months ago
release.nix hasql-migration override removed (#30) 10 months ago
shell.nix update pinned nix rev (#26) 10 months ago


Generic badge

Migratum is a PostgreSQL migration utility.

Migratum: PostgreSQL Migration Tool

Usage: migratum COMMAND
  Migratum is a database tool that manages migrations

Available options:
  -h,--help                Show this help text

Available commands:
  new                      Generate necessary files for migration
  init                     Initialize database for migration
  migrate                  Perform Migration

Initial Setup

Database Connection

$ migratum new

This comment will generate the migrations directory which will contain


migratum.yaml will contain the field below, which you can fill in with your database information.


Once these fields have been filled in, perform this command

$ migratum init

This will create a table called schema_migrations. This table will store the information about the migrations that have been executed in the database


Write your migration file in the sql directory with this convention.

V<version number>__<name of migration>.sql

For example:


After you are done writing your migration script, perform this command

$ migratum migrate

You should see this response in your terminal

[Info]: MigrationPerformed V1__uuid_extension.sql