Something went wrong. Try again.
A collection of +180 reusable WebAssembly modules for building composable CI/CD pipelines with FluentCI fluentci.io/modules
Something went wrong. Try again.
123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394-- Generated by Gleam CI helpers.module CI.Component (run, version, init, validate, start, complete, rollback, migrate, status, analyze, baseline, pull, convert, update, create, latest, latest_migration, latest_schema, latest_url, completion) where
import Preludeimport CI.Contract as Contractimport Data.Maybe (Maybe)import Effect (Effect)import CI.ModuleDependencies as Dependenciesimport CI.CLI as Native
-- | Execute any pgroll feature with literal CSV arguments.-- | @param project Working directory containing the source checkout; defaults to the current directory. Default: ".".-- | @param runDir Fresh directory for this invocation’s execution report and task logs; must not already exist.-- | @param executable Native CLI executable name or absolute path; defaults to this operation’s tool.-- | @param timeoutMs Maximum task duration in milliseconds; defaults to 900000. Default: 900000.-- | @param artifacts Comma-separated NAME=PATH output artifacts; use CSV double quotes around entries containing commas.-- | @param arguments Additional literal CLI tokens as comma-separated text; double-quote CSV entries containing commas and double embedded quotes. No shell expansion occurs.run :: { project :: Maybe String, runDir :: String, executable :: Maybe String, timeoutMs :: Maybe Int, artifacts :: Maybe String, arguments :: String } -> Effect Contract.ExecutionResultrun args = do json <- Native.csvInput (Contract.input (Contract.encodeInput args)) >>= Contract.cliInput Native.executeWithSetup Dependencies.ensureFor "pgroll" "run" json
-- | Print the installed pgroll version.-- | @param project Working directory containing the source checkout; defaults to the current directory. Default: ".".-- | @param runDir Fresh directory for this invocation’s execution report and task logs; must not already exist.-- | @param executable Native CLI executable name or absolute path; defaults to this operation’s tool.-- | @param timeoutMs Maximum task duration in milliseconds; defaults to 900000. Default: 900000.-- | @param artifacts Comma-separated NAME=PATH output artifacts; use CSV double quotes around entries containing commas.version :: { project :: Maybe String, runDir :: String, executable :: Maybe String, timeoutMs :: Maybe Int, artifacts :: Maybe String } -> Effect Contract.ExecutionResultversion args = do json <- Native.csvInput (Contract.input (Contract.encodeInput args)) >>= Contract.cliInput Native.executeWithSetup Dependencies.ensureFor "pgroll" "version" json
-- | Initialize pgroll state in the target database; no migration file is required.-- | @param project Working directory containing the source checkout; defaults to the current directory. Default: ".".-- | @param runDir Fresh directory for this invocation’s execution report and task logs; must not already exist.-- | @param executable Native CLI executable name or absolute path; defaults to this operation’s tool.-- | @param timeoutMs Maximum task duration in milliseconds; defaults to 900000. Default: 900000.-- | @param artifacts Comma-separated NAME=PATH output artifacts; use CSV double quotes around entries containing commas.-- | @param postgresUrl PostgreSQL connection URL; prefer inherited PGROLL_PG_URL for credentials because explicit arguments appear in execution plans.-- | @param schema PostgreSQL schema to migrate; native default public.-- | @param stateSchema Schema containing pgroll internal state; native default pgroll.-- | @param lockTimeout PostgreSQL DDL lock timeout in milliseconds; native default 500.-- | @param role Optional PostgreSQL role used while executing migrations.-- | @param useVersionSchema Create version schemas for migrations; native default true. Explicit false is passed through.-- | @param verbose Enable native verbose logging.-- | @param arguments Additional literal CLI tokens as comma-separated text; double-quote CSV entries containing commas and double embedded quotes. No shell expansion occurs.init :: { project :: Maybe String, runDir :: String, executable :: Maybe String, timeoutMs :: Maybe Int, artifacts :: Maybe String, postgresUrl :: Maybe String, schema :: Maybe String, stateSchema :: Maybe String, lockTimeout :: Maybe Int, role :: Maybe String, useVersionSchema :: Maybe Boolean, verbose :: Maybe Boolean, arguments :: Maybe String } -> Effect Contract.ExecutionResultinit args = do json <- Native.csvInput (Contract.input (Contract.encodeInput args)) >>= Contract.cliInput Native.executeWithSetup Dependencies.ensureFor "pgroll" "init" json
-- | Validate a migration file against the target database before application.-- | @param project Working directory containing the source checkout; defaults to the current directory. Default: ".".-- | @param runDir Fresh directory for this invocation’s execution report and task logs; must not already exist.-- | @param executable Native CLI executable name or absolute path; defaults to this operation’s tool.-- | @param timeoutMs Maximum task duration in milliseconds; defaults to 900000. Default: 900000.-- | @param artifacts Comma-separated NAME=PATH output artifacts; use CSV double quotes around entries containing commas.-- | @param postgresUrl PostgreSQL connection URL; prefer inherited PGROLL_PG_URL for credentials because explicit arguments appear in execution plans.-- | @param schema PostgreSQL schema to migrate; native default public.-- | @param stateSchema Schema containing pgroll internal state; native default pgroll.-- | @param lockTimeout PostgreSQL DDL lock timeout in milliseconds; native default 500.-- | @param role Optional PostgreSQL role used while executing migrations.-- | @param useVersionSchema Create version schemas for migrations; native default true. Explicit false is passed through.-- | @param verbose Enable native verbose logging.-- | @param file Existing YAML or JSON migration file to validate against the target database.-- | @param arguments Additional literal CLI tokens as comma-separated text; double-quote CSV entries containing commas and double embedded quotes. No shell expansion occurs.validate :: { project :: Maybe String, runDir :: String, executable :: Maybe String, timeoutMs :: Maybe Int, artifacts :: Maybe String, postgresUrl :: Maybe String, schema :: Maybe String, stateSchema :: Maybe String, lockTimeout :: Maybe Int, role :: Maybe String, useVersionSchema :: Maybe Boolean, verbose :: Maybe Boolean, file :: String, arguments :: Maybe String } -> Effect Contract.ExecutionResultvalidate args = do json <- Native.csvInput (Contract.input (Contract.encodeInput args)) >>= Contract.cliInput Native.executeWithSetup Dependencies.ensureFor "pgroll" "validate" json
-- | Start a migration, backfill data, and optionally complete it.-- | @param project Working directory containing the source checkout; defaults to the current directory. Default: ".".-- | @param runDir Fresh directory for this invocation’s execution report and task logs; must not already exist.-- | @param executable Native CLI executable name or absolute path; defaults to this operation’s tool.-- | @param timeoutMs Maximum task duration in milliseconds; defaults to 900000. Default: 900000.-- | @param artifacts Comma-separated NAME=PATH output artifacts; use CSV double quotes around entries containing commas.-- | @param postgresUrl PostgreSQL connection URL; prefer inherited PGROLL_PG_URL for credentials because explicit arguments appear in execution plans.-- | @param schema PostgreSQL schema to migrate; native default public.-- | @param stateSchema Schema containing pgroll internal state; native default pgroll.-- | @param lockTimeout PostgreSQL DDL lock timeout in milliseconds; native default 500.-- | @param role Optional PostgreSQL role used while executing migrations.-- | @param useVersionSchema Create version schemas for migrations; native default true. Explicit false is passed through.-- | @param verbose Enable native verbose logging.-- | @param file Existing YAML or JSON migration file to start.-- | @param backfillBatchDelay Delay between backfill batches as a Go duration, for example 1s or 1000ms.-- | @param backfillBatchSize Positive number of rows per backfill batch; native default 1000.-- | @param complete Complete the migration immediately after applying it; native default false.-- | @param skipValidation Explicitly bypass native migration validation; native default false.-- | @param arguments Additional literal CLI tokens as comma-separated text; double-quote CSV entries containing commas and double embedded quotes. No shell expansion occurs.start :: { project :: Maybe String, runDir :: String, executable :: Maybe String, timeoutMs :: Maybe Int, artifacts :: Maybe String, postgresUrl :: Maybe String, schema :: Maybe String, stateSchema :: Maybe String, lockTimeout :: Maybe Int, role :: Maybe String, useVersionSchema :: Maybe Boolean, verbose :: Maybe Boolean, file :: String, backfillBatchDelay :: Maybe String, backfillBatchSize :: Maybe Int, complete :: Maybe Boolean, skipValidation :: Maybe Boolean, arguments :: Maybe String } -> Effect Contract.ExecutionResultstart args = do json <- Native.csvInput (Contract.input (Contract.encodeInput args)) >>= Contract.cliInput Native.executeWithSetup Dependencies.ensureFor "pgroll" "start" json
-- | Complete the currently active migration in the database; no migration file is required.-- | @param project Working directory containing the source checkout; defaults to the current directory. Default: ".".-- | @param runDir Fresh directory for this invocation’s execution report and task logs; must not already exist.-- | @param executable Native CLI executable name or absolute path; defaults to this operation’s tool.-- | @param timeoutMs Maximum task duration in milliseconds; defaults to 900000. Default: 900000.-- | @param artifacts Comma-separated NAME=PATH output artifacts; use CSV double quotes around entries containing commas.-- | @param postgresUrl PostgreSQL connection URL; prefer inherited PGROLL_PG_URL for credentials because explicit arguments appear in execution plans.-- | @param schema PostgreSQL schema to migrate; native default public.-- | @param stateSchema Schema containing pgroll internal state; native default pgroll.-- | @param lockTimeout PostgreSQL DDL lock timeout in milliseconds; native default 500.-- | @param role Optional PostgreSQL role used while executing migrations.-- | @param useVersionSchema Create version schemas for migrations; native default true. Explicit false is passed through.-- | @param verbose Enable native verbose logging.-- | @param arguments Additional literal CLI tokens as comma-separated text; double-quote CSV entries containing commas and double embedded quotes. No shell expansion occurs.complete :: { project :: Maybe String, runDir :: String, executable :: Maybe String, timeoutMs :: Maybe Int, artifacts :: Maybe String, postgresUrl :: Maybe String, schema :: Maybe String, stateSchema :: Maybe String, lockTimeout :: Maybe Int, role :: Maybe String, useVersionSchema :: Maybe Boolean, verbose :: Maybe Boolean, arguments :: Maybe String } -> Effect Contract.ExecutionResultcomplete args = do json <- Native.csvInput (Contract.input (Contract.encodeInput args)) >>= Contract.cliInput Native.executeWithSetup Dependencies.ensureFor "pgroll" "complete" json
-- | Roll back the currently active migration; completed migrations retain native rollback limitations.-- | @param project Working directory containing the source checkout; defaults to the current directory. Default: ".".-- | @param runDir Fresh directory for this invocation’s execution report and task logs; must not already exist.-- | @param executable Native CLI executable name or absolute path; defaults to this operation’s tool.-- | @param timeoutMs Maximum task duration in milliseconds; defaults to 900000. Default: 900000.-- | @param artifacts Comma-separated NAME=PATH output artifacts; use CSV double quotes around entries containing commas.-- | @param postgresUrl PostgreSQL connection URL; prefer inherited PGROLL_PG_URL for credentials because explicit arguments appear in execution plans.-- | @param schema PostgreSQL schema to migrate; native default public.-- | @param stateSchema Schema containing pgroll internal state; native default pgroll.-- | @param lockTimeout PostgreSQL DDL lock timeout in milliseconds; native default 500.-- | @param role Optional PostgreSQL role used while executing migrations.-- | @param useVersionSchema Create version schemas for migrations; native default true. Explicit false is passed through.-- | @param verbose Enable native verbose logging.-- | @param arguments Additional literal CLI tokens as comma-separated text; double-quote CSV entries containing commas and double embedded quotes. No shell expansion occurs.rollback :: { project :: Maybe String, runDir :: String, executable :: Maybe String, timeoutMs :: Maybe Int, artifacts :: Maybe String, postgresUrl :: Maybe String, schema :: Maybe String, stateSchema :: Maybe String, lockTimeout :: Maybe Int, role :: Maybe String, useVersionSchema :: Maybe Boolean, verbose :: Maybe Boolean, arguments :: Maybe String } -> Effect Contract.ExecutionResultrollback args = do json <- Native.csvInput (Contract.input (Contract.encodeInput args)) >>= Contract.cliInput Native.executeWithSetup Dependencies.ensureFor "pgroll" "rollback" json
-- | Apply outstanding migrations from a directory and propagate native failures.-- | @param project Working directory containing the source checkout; defaults to the current directory. Default: ".".-- | @param runDir Fresh directory for this invocation’s execution report and task logs; must not already exist.-- | @param executable Native CLI executable name or absolute path; defaults to this operation’s tool.-- | @param timeoutMs Maximum task duration in milliseconds; defaults to 900000. Default: 900000.-- | @param artifacts Comma-separated NAME=PATH output artifacts; use CSV double quotes around entries containing commas.-- | @param postgresUrl PostgreSQL connection URL; prefer inherited PGROLL_PG_URL for credentials because explicit arguments appear in execution plans.-- | @param schema PostgreSQL schema to migrate; native default public.-- | @param stateSchema Schema containing pgroll internal state; native default pgroll.-- | @param lockTimeout PostgreSQL DDL lock timeout in milliseconds; native default 500.-- | @param role Optional PostgreSQL role used while executing migrations.-- | @param useVersionSchema Create version schemas for migrations; native default true. Explicit false is passed through.-- | @param verbose Enable native verbose logging.-- | @param directory Existing directory containing ordered migration files.-- | @param backfillBatchDelay Delay between backfill batches as a Go duration, for example 1s or 1000ms.-- | @param backfillBatchSize Positive number of rows per backfill batch; native default 1000.-- | @param complete Complete the final migration instead of leaving it active.-- | @param expectOne Abort when more than one outstanding migration would be applied.-- | @param arguments Additional literal CLI tokens as comma-separated text; double-quote CSV entries containing commas and double embedded quotes. No shell expansion occurs.migrate :: { project :: Maybe String, runDir :: String, executable :: Maybe String, timeoutMs :: Maybe Int, artifacts :: Maybe String, postgresUrl :: Maybe String, schema :: Maybe String, stateSchema :: Maybe String, lockTimeout :: Maybe Int, role :: Maybe String, useVersionSchema :: Maybe Boolean, verbose :: Maybe Boolean, directory :: String, backfillBatchDelay :: Maybe String, backfillBatchSize :: Maybe Int, complete :: Maybe Boolean, expectOne :: Maybe Boolean, arguments :: Maybe String } -> Effect Contract.ExecutionResultmigrate args = do json <- Native.csvInput (Contract.input (Contract.encodeInput args)) >>= Contract.cliInput Native.executeWithSetup Dependencies.ensureFor "pgroll" "migrate" json
-- | Report active migration and schema state in the target database.-- | @param project Working directory containing the source checkout; defaults to the current directory. Default: ".".-- | @param runDir Fresh directory for this invocation’s execution report and task logs; must not already exist.-- | @param executable Native CLI executable name or absolute path; defaults to this operation’s tool.-- | @param timeoutMs Maximum task duration in milliseconds; defaults to 900000. Default: 900000.-- | @param artifacts Comma-separated NAME=PATH output artifacts; use CSV double quotes around entries containing commas.-- | @param postgresUrl PostgreSQL connection URL; prefer inherited PGROLL_PG_URL for credentials because explicit arguments appear in execution plans.-- | @param schema PostgreSQL schema to migrate; native default public.-- | @param stateSchema Schema containing pgroll internal state; native default pgroll.-- | @param lockTimeout PostgreSQL DDL lock timeout in milliseconds; native default 500.-- | @param role Optional PostgreSQL role used while executing migrations.-- | @param useVersionSchema Create version schemas for migrations; native default true. Explicit false is passed through.-- | @param verbose Enable native verbose logging.-- | @param arguments Additional literal CLI tokens as comma-separated text; double-quote CSV entries containing commas and double embedded quotes. No shell expansion occurs.status :: { project :: Maybe String, runDir :: String, executable :: Maybe String, timeoutMs :: Maybe Int, artifacts :: Maybe String, postgresUrl :: Maybe String, schema :: Maybe String, stateSchema :: Maybe String, lockTimeout :: Maybe Int, role :: Maybe String, useVersionSchema :: Maybe Boolean, verbose :: Maybe Boolean, arguments :: Maybe String } -> Effect Contract.ExecutionResultstatus args = do json <- Native.csvInput (Contract.input (Contract.encodeInput args)) >>= Contract.cliInput Native.executeWithSetup Dependencies.ensureFor "pgroll" "status" json
-- | Analyze the target database SQL schema using the native hidden diagnostic command.-- | @param project Working directory containing the source checkout; defaults to the current directory. Default: ".".-- | @param runDir Fresh directory for this invocation’s execution report and task logs; must not already exist.-- | @param executable Native CLI executable name or absolute path; defaults to this operation’s tool.-- | @param timeoutMs Maximum task duration in milliseconds; defaults to 900000. Default: 900000.-- | @param artifacts Comma-separated NAME=PATH output artifacts; use CSV double quotes around entries containing commas.-- | @param postgresUrl PostgreSQL connection URL; prefer inherited PGROLL_PG_URL for credentials because explicit arguments appear in execution plans.-- | @param schema PostgreSQL schema to migrate; native default public.-- | @param stateSchema Schema containing pgroll internal state; native default pgroll.-- | @param lockTimeout PostgreSQL DDL lock timeout in milliseconds; native default 500.-- | @param role Optional PostgreSQL role used while executing migrations.-- | @param useVersionSchema Create version schemas for migrations; native default true. Explicit false is passed through.-- | @param verbose Enable native verbose logging.-- | @param arguments Additional literal CLI tokens as comma-separated text; double-quote CSV entries containing commas and double embedded quotes. No shell expansion occurs.analyze :: { project :: Maybe String, runDir :: String, executable :: Maybe String, timeoutMs :: Maybe Int, artifacts :: Maybe String, postgresUrl :: Maybe String, schema :: Maybe String, stateSchema :: Maybe String, lockTimeout :: Maybe Int, role :: Maybe String, useVersionSchema :: Maybe Boolean, verbose :: Maybe Boolean, arguments :: Maybe String } -> Effect Contract.ExecutionResultanalyze args = do json <- Native.csvInput (Contract.input (Contract.encodeInput args)) >>= Contract.cliInput Native.executeWithSetup Dependencies.ensureFor "pgroll" "analyze" json
-- | Reset migration history to a baseline and write its placeholder file without a confirmation prompt.-- | @param project Working directory containing the source checkout; defaults to the current directory. Default: ".".-- | @param runDir Fresh directory for this invocation’s execution report and task logs; must not already exist.-- | @param executable Native CLI executable name or absolute path; defaults to this operation’s tool.-- | @param timeoutMs Maximum task duration in milliseconds; defaults to 900000. Default: 900000.-- | @param artifacts Comma-separated NAME=PATH output artifacts; use CSV double quotes around entries containing commas.-- | @param postgresUrl PostgreSQL connection URL; prefer inherited PGROLL_PG_URL for credentials because explicit arguments appear in execution plans.-- | @param schema PostgreSQL schema to migrate; native default public.-- | @param stateSchema Schema containing pgroll internal state; native default pgroll.-- | @param lockTimeout PostgreSQL DDL lock timeout in milliseconds; native default 500.-- | @param role Optional PostgreSQL role used while executing migrations.-- | @param useVersionSchema Create version schemas for migrations; native default true. Explicit false is passed through.-- | @param verbose Enable native verbose logging.-- | @param baselineVersion Name of the baseline migration; this resets migration history.-- | @param directory Directory for the generated baseline file; created by pgroll if absent.-- | @param json Write migration files in JSON instead of YAML.-- | @param arguments Additional literal CLI tokens as comma-separated text; double-quote CSV entries containing commas and double embedded quotes. No shell expansion occurs.baseline :: { project :: Maybe String, runDir :: String, executable :: Maybe String, timeoutMs :: Maybe Int, artifacts :: Maybe String, postgresUrl :: Maybe String, schema :: Maybe String, stateSchema :: Maybe String, lockTimeout :: Maybe Int, role :: Maybe String, useVersionSchema :: Maybe Boolean, verbose :: Maybe Boolean, baselineVersion :: String, directory :: String, json :: Maybe Boolean, arguments :: Maybe String } -> Effect Contract.ExecutionResultbaseline args = do json <- Native.csvInput (Contract.input (Contract.encodeInput args)) >>= Contract.cliInput Native.executeWithSetup Dependencies.ensureFor "pgroll" "baseline" json
-- | Pull missing migration history from the database into local files.-- | @param project Working directory containing the source checkout; defaults to the current directory. Default: ".".-- | @param runDir Fresh directory for this invocation’s execution report and task logs; must not already exist.-- | @param executable Native CLI executable name or absolute path; defaults to this operation’s tool.-- | @param timeoutMs Maximum task duration in milliseconds; defaults to 900000. Default: 900000.-- | @param artifacts Comma-separated NAME=PATH output artifacts; use CSV double quotes around entries containing commas.-- | @param postgresUrl PostgreSQL connection URL; prefer inherited PGROLL_PG_URL for credentials because explicit arguments appear in execution plans.-- | @param schema PostgreSQL schema to migrate; native default public.-- | @param stateSchema Schema containing pgroll internal state; native default pgroll.-- | @param lockTimeout PostgreSQL DDL lock timeout in milliseconds; native default 500.-- | @param role Optional PostgreSQL role used while executing migrations.-- | @param useVersionSchema Create version schemas for migrations; native default true. Explicit false is passed through.-- | @param verbose Enable native verbose logging.-- | @param directory Destination directory for migration history; created by pgroll if absent.-- | @param json Write migration files in JSON instead of YAML.-- | @param arguments Additional literal CLI tokens as comma-separated text; double-quote CSV entries containing commas and double embedded quotes. No shell expansion occurs.pull :: { project :: Maybe String, runDir :: String, executable :: Maybe String, timeoutMs :: Maybe Int, artifacts :: Maybe String, postgresUrl :: Maybe String, schema :: Maybe String, stateSchema :: Maybe String, lockTimeout :: Maybe Int, role :: Maybe String, useVersionSchema :: Maybe Boolean, verbose :: Maybe Boolean, directory :: String, json :: Maybe Boolean, arguments :: Maybe String } -> Effect Contract.ExecutionResultpull args = do json <- Native.csvInput (Contract.input (Contract.encodeInput args)) >>= Contract.cliInput Native.executeWithSetup Dependencies.ensureFor "pgroll" "pull" json
-- | Convert SQL statements from a file to a pgroll migration using native conversion rules.-- | @param project Working directory containing the source checkout; defaults to the current directory. Default: ".".-- | @param runDir Fresh directory for this invocation’s execution report and task logs; must not already exist.-- | @param executable Native CLI executable name or absolute path; defaults to this operation’s tool.-- | @param timeoutMs Maximum task duration in milliseconds; defaults to 900000. Default: 900000.-- | @param artifacts Comma-separated NAME=PATH output artifacts; use CSV double quotes around entries containing commas.-- | @param postgresUrl PostgreSQL connection URL; prefer inherited PGROLL_PG_URL for credentials because explicit arguments appear in execution plans.-- | @param schema PostgreSQL schema to migrate; native default public.-- | @param stateSchema Schema containing pgroll internal state; native default pgroll.-- | @param lockTimeout PostgreSQL DDL lock timeout in milliseconds; native default 500.-- | @param role Optional PostgreSQL role used while executing migrations.-- | @param useVersionSchema Create version schemas for migrations; native default true. Explicit false is passed through.-- | @param verbose Enable native verbose logging.-- | @param file Existing SQL input file to convert to a pgroll migration.-- | @param json Write migration files in JSON instead of YAML.-- | @param arguments Additional literal CLI tokens as comma-separated text; double-quote CSV entries containing commas and double embedded quotes. No shell expansion occurs.convert :: { project :: Maybe String, runDir :: String, executable :: Maybe String, timeoutMs :: Maybe Int, artifacts :: Maybe String, postgresUrl :: Maybe String, schema :: Maybe String, stateSchema :: Maybe String, lockTimeout :: Maybe Int, role :: Maybe String, useVersionSchema :: Maybe Boolean, verbose :: Maybe Boolean, file :: String, json :: Maybe Boolean, arguments :: Maybe String } -> Effect Contract.ExecutionResultconvert args = do json <- Native.csvInput (Contract.input (Contract.encodeInput args)) >>= Contract.cliInput Native.executeWithSetup Dependencies.ensureFor "pgroll" "convert" json
-- | Rewrite outdated migration files in place; review changes before committing them.-- | @param project Working directory containing the source checkout; defaults to the current directory. Default: ".".-- | @param runDir Fresh directory for this invocation’s execution report and task logs; must not already exist.-- | @param executable Native CLI executable name or absolute path; defaults to this operation’s tool.-- | @param timeoutMs Maximum task duration in milliseconds; defaults to 900000. Default: 900000.-- | @param artifacts Comma-separated NAME=PATH output artifacts; use CSV double quotes around entries containing commas.-- | @param postgresUrl PostgreSQL connection URL; prefer inherited PGROLL_PG_URL for credentials because explicit arguments appear in execution plans.-- | @param schema PostgreSQL schema to migrate; native default public.-- | @param stateSchema Schema containing pgroll internal state; native default pgroll.-- | @param lockTimeout PostgreSQL DDL lock timeout in milliseconds; native default 500.-- | @param role Optional PostgreSQL role used while executing migrations.-- | @param useVersionSchema Create version schemas for migrations; native default true. Explicit false is passed through.-- | @param verbose Enable native verbose logging.-- | @param directory Existing directory of migration files to rewrite to the current format.-- | @param json Write migration files in JSON instead of YAML.-- | @param arguments Additional literal CLI tokens as comma-separated text; double-quote CSV entries containing commas and double embedded quotes. No shell expansion occurs.update :: { project :: Maybe String, runDir :: String, executable :: Maybe String, timeoutMs :: Maybe Int, artifacts :: Maybe String, postgresUrl :: Maybe String, schema :: Maybe String, stateSchema :: Maybe String, lockTimeout :: Maybe Int, role :: Maybe String, useVersionSchema :: Maybe Boolean, verbose :: Maybe Boolean, directory :: String, json :: Maybe Boolean, arguments :: Maybe String } -> Effect Contract.ExecutionResultupdate args = do json <- Native.csvInput (Contract.input (Contract.encodeInput args)) >>= Contract.cliInput Native.executeWithSetup Dependencies.ensureFor "pgroll" "update" json
-- | Create an empty named migration file noninteractively in the working directory.-- | @param project Working directory containing the source checkout; defaults to the current directory. Default: ".".-- | @param runDir Fresh directory for this invocation’s execution report and task logs; must not already exist.-- | @param executable Native CLI executable name or absolute path; defaults to this operation’s tool.-- | @param timeoutMs Maximum task duration in milliseconds; defaults to 900000. Default: 900000.-- | @param artifacts Comma-separated NAME=PATH output artifacts; use CSV double quotes around entries containing commas.-- | @param postgresUrl PostgreSQL connection URL; prefer inherited PGROLL_PG_URL for credentials because explicit arguments appear in execution plans.-- | @param schema PostgreSQL schema to migrate; native default public.-- | @param stateSchema Schema containing pgroll internal state; native default pgroll.-- | @param lockTimeout PostgreSQL DDL lock timeout in milliseconds; native default 500.-- | @param role Optional PostgreSQL role used while executing migrations.-- | @param useVersionSchema Create version schemas for migrations; native default true. Explicit false is passed through.-- | @param verbose Enable native verbose logging.-- | @param name Migration filename stem, including a relative path if desired; pgroll adds .yaml or .json.-- | @param json Write migration files in JSON instead of YAML.-- | @param arguments Additional literal CLI tokens as comma-separated text; double-quote CSV entries containing commas and double embedded quotes. No shell expansion occurs.create :: { project :: Maybe String, runDir :: String, executable :: Maybe String, timeoutMs :: Maybe Int, artifacts :: Maybe String, postgresUrl :: Maybe String, schema :: Maybe String, stateSchema :: Maybe String, lockTimeout :: Maybe Int, role :: Maybe String, useVersionSchema :: Maybe Boolean, verbose :: Maybe Boolean, name :: String, json :: Maybe Boolean, arguments :: Maybe String } -> Effect Contract.ExecutionResultcreate args = do json <- Native.csvInput (Contract.input (Contract.encodeInput args)) >>= Contract.cliInput Native.executeWithSetup Dependencies.ensureFor "pgroll" "create" json
-- | Access native latest subcommands through the CSV arguments string.-- | @param project Working directory containing the source checkout; defaults to the current directory. Default: ".".-- | @param runDir Fresh directory for this invocation’s execution report and task logs; must not already exist.-- | @param executable Native CLI executable name or absolute path; defaults to this operation’s tool.-- | @param timeoutMs Maximum task duration in milliseconds; defaults to 900000. Default: 900000.-- | @param artifacts Comma-separated NAME=PATH output artifacts; use CSV double quotes around entries containing commas.-- | @param postgresUrl PostgreSQL connection URL; prefer inherited PGROLL_PG_URL for credentials because explicit arguments appear in execution plans.-- | @param schema PostgreSQL schema to migrate; native default public.-- | @param stateSchema Schema containing pgroll internal state; native default pgroll.-- | @param lockTimeout PostgreSQL DDL lock timeout in milliseconds; native default 500.-- | @param role Optional PostgreSQL role used while executing migrations.-- | @param useVersionSchema Create version schemas for migrations; native default true. Explicit false is passed through.-- | @param verbose Enable native verbose logging.-- | @param arguments Additional literal CLI tokens as comma-separated text; double-quote CSV entries containing commas and double embedded quotes. No shell expansion occurs.latest :: { project :: Maybe String, runDir :: String, executable :: Maybe String, timeoutMs :: Maybe Int, artifacts :: Maybe String, postgresUrl :: Maybe String, schema :: Maybe String, stateSchema :: Maybe String, lockTimeout :: Maybe Int, role :: Maybe String, useVersionSchema :: Maybe Boolean, verbose :: Maybe Boolean, arguments :: Maybe String } -> Effect Contract.ExecutionResultlatest args = do json <- Native.csvInput (Contract.input (Contract.encodeInput args)) >>= Contract.cliInput Native.executeWithSetup Dependencies.ensureFor "pgroll" "latest" json
-- | Print the latest migration from the target database or local migration directory.-- | @param project Working directory containing the source checkout; defaults to the current directory. Default: ".".-- | @param runDir Fresh directory for this invocation’s execution report and task logs; must not already exist.-- | @param executable Native CLI executable name or absolute path; defaults to this operation’s tool.-- | @param timeoutMs Maximum task duration in milliseconds; defaults to 900000. Default: 900000.-- | @param artifacts Comma-separated NAME=PATH output artifacts; use CSV double quotes around entries containing commas.-- | @param postgresUrl PostgreSQL connection URL; prefer inherited PGROLL_PG_URL for credentials because explicit arguments appear in execution plans.-- | @param schema PostgreSQL schema to migrate; native default public.-- | @param stateSchema Schema containing pgroll internal state; native default pgroll.-- | @param lockTimeout PostgreSQL DDL lock timeout in milliseconds; native default 500.-- | @param role Optional PostgreSQL role used while executing migrations.-- | @param useVersionSchema Create version schemas for migrations; native default true. Explicit false is passed through.-- | @param verbose Enable native verbose logging.-- | @param local Existing local migration directory; omit to discover the latest version from the target database.-- | @param arguments Additional literal CLI tokens as comma-separated text; double-quote CSV entries containing commas and double embedded quotes. No shell expansion occurs.latest_migration :: { project :: Maybe String, runDir :: String, executable :: Maybe String, timeoutMs :: Maybe Int, artifacts :: Maybe String, postgresUrl :: Maybe String, schema :: Maybe String, stateSchema :: Maybe String, lockTimeout :: Maybe Int, role :: Maybe String, useVersionSchema :: Maybe Boolean, verbose :: Maybe Boolean, local :: Maybe String, arguments :: Maybe String } -> Effect Contract.ExecutionResultlatest_migration args = do json <- Native.csvInput (Contract.input (Contract.encodeInput args)) >>= Contract.cliInput Native.executeWithSetup Dependencies.ensureFor "pgroll" "latest_migration" json
-- | Print the latest schema from the target database or local migration directory.-- | @param project Working directory containing the source checkout; defaults to the current directory. Default: ".".-- | @param runDir Fresh directory for this invocation’s execution report and task logs; must not already exist.-- | @param executable Native CLI executable name or absolute path; defaults to this operation’s tool.-- | @param timeoutMs Maximum task duration in milliseconds; defaults to 900000. Default: 900000.-- | @param artifacts Comma-separated NAME=PATH output artifacts; use CSV double quotes around entries containing commas.-- | @param postgresUrl PostgreSQL connection URL; prefer inherited PGROLL_PG_URL for credentials because explicit arguments appear in execution plans.-- | @param schema PostgreSQL schema to migrate; native default public.-- | @param stateSchema Schema containing pgroll internal state; native default pgroll.-- | @param lockTimeout PostgreSQL DDL lock timeout in milliseconds; native default 500.-- | @param role Optional PostgreSQL role used while executing migrations.-- | @param useVersionSchema Create version schemas for migrations; native default true. Explicit false is passed through.-- | @param verbose Enable native verbose logging.-- | @param local Existing local migration directory; omit to discover the latest version from the target database.-- | @param arguments Additional literal CLI tokens as comma-separated text; double-quote CSV entries containing commas and double embedded quotes. No shell expansion occurs.latest_schema :: { project :: Maybe String, runDir :: String, executable :: Maybe String, timeoutMs :: Maybe Int, artifacts :: Maybe String, postgresUrl :: Maybe String, schema :: Maybe String, stateSchema :: Maybe String, lockTimeout :: Maybe Int, role :: Maybe String, useVersionSchema :: Maybe Boolean, verbose :: Maybe Boolean, local :: Maybe String, arguments :: Maybe String } -> Effect Contract.ExecutionResultlatest_schema args = do json <- Native.csvInput (Contract.input (Contract.encodeInput args)) >>= Contract.cliInput Native.executeWithSetup Dependencies.ensureFor "pgroll" "latest_schema" json
-- | Print the latest connection URL with version schema search_path from the target database or local migration directory.-- | @param project Working directory containing the source checkout; defaults to the current directory. Default: ".".-- | @param runDir Fresh directory for this invocation’s execution report and task logs; must not already exist.-- | @param executable Native CLI executable name or absolute path; defaults to this operation’s tool.-- | @param timeoutMs Maximum task duration in milliseconds; defaults to 900000. Default: 900000.-- | @param artifacts Comma-separated NAME=PATH output artifacts; use CSV double quotes around entries containing commas.-- | @param postgresUrl PostgreSQL connection URL; prefer inherited PGROLL_PG_URL for credentials because explicit arguments appear in execution plans.-- | @param schema PostgreSQL schema to migrate; native default public.-- | @param stateSchema Schema containing pgroll internal state; native default pgroll.-- | @param lockTimeout PostgreSQL DDL lock timeout in milliseconds; native default 500.-- | @param role Optional PostgreSQL role used while executing migrations.-- | @param useVersionSchema Create version schemas for migrations; native default true. Explicit false is passed through.-- | @param verbose Enable native verbose logging.-- | @param local Existing local migration directory; omit to discover the latest version from the target database.-- | @param connectionString Optional connection URL to rewrite; omit to use PGROLL_PG_URL or postgresUrl. Output may contain credentials.-- | @param arguments Additional literal CLI tokens as comma-separated text; double-quote CSV entries containing commas and double embedded quotes. No shell expansion occurs.latest_url :: { project :: Maybe String, runDir :: String, executable :: Maybe String, timeoutMs :: Maybe Int, artifacts :: Maybe String, postgresUrl :: Maybe String, schema :: Maybe String, stateSchema :: Maybe String, lockTimeout :: Maybe Int, role :: Maybe String, useVersionSchema :: Maybe Boolean, verbose :: Maybe Boolean, local :: Maybe String, connectionString :: Maybe String, arguments :: Maybe String } -> Effect Contract.ExecutionResultlatest_url args = do json <- Native.csvInput (Contract.input (Contract.encodeInput args)) >>= Contract.cliInput Native.executeWithSetup Dependencies.ensureFor "pgroll" "latest_url" json
-- | Generate shell completion scripts through literal native CSV arguments.-- | @param project Working directory containing the source checkout; defaults to the current directory. Default: ".".-- | @param runDir Fresh directory for this invocation’s execution report and task logs; must not already exist.-- | @param executable Native CLI executable name or absolute path; defaults to this operation’s tool.-- | @param timeoutMs Maximum task duration in milliseconds; defaults to 900000. Default: 900000.-- | @param artifacts Comma-separated NAME=PATH output artifacts; use CSV double quotes around entries containing commas.-- | @param arguments Additional literal CLI tokens as comma-separated text; double-quote CSV entries containing commas and double embedded quotes. No shell expansion occurs.completion :: { project :: Maybe String, runDir :: String, executable :: Maybe String, timeoutMs :: Maybe Int, artifacts :: Maybe String, arguments :: Maybe String } -> Effect Contract.ExecutionResultcompletion args = do json <- Native.csvInput (Contract.input (Contract.encodeInput args)) >>= Contract.cliInput Native.executeWithSetup Dependencies.ensureFor "pgroll" "completion" json