package migra

  1. Overview
  2. Docs
A database migration tool and library for OCaml supporting PostgreSQL, MariaDB/MySQL, and SQLite

Install

dune-project
 Dependency

Authors

Maintainers

Sources

migra-1.0.1.tbz
sha256=daaaab416e580e5b8dc9f0a74482e142cef6d77b248d995d320f6f882d3a9e35
sha512=8f60494b9ee6ac2e7e69a16eefce69d1e8c22e831fe28f600a42200e3086e2f4d15331323ad1848f7165e1c8ff30fe320445185b7e988325588293a66937966a

doc/migra.engine/Migra_engine/Discovery/index.html

Module Migra_engine.DiscoverySource

Sourcemodule Int64Set : Set.S with type elt = int64
Sourceval default_migrations_dir : string
Sourceval applied_set_of_list : int64 list -> Int64Set.t
Sourceval is_migration_file : string -> bool
Sourceval read_directory : string -> (string list, Types.error) result
Sourceval find_migrations : ?dir:string -> unit -> (Migration.t list, Types.error) result
Sourceval find_pending : int64 list -> Migration.t list -> Migration.t list

Find pending migrations (not yet applied). Takes a list of applied versions and all discovered migrations, returns migrations that haven't been applied yet.

Sourceval find_by_version : Migration.t list -> int64 -> Migration.t option
Sourceval ensure_migrations_dir : ?dir:string -> unit -> (unit, Types.error) result