Module

x/nessie/cli/state.ts>State

A modular Deno library for PostgreSQL, MySQL, MariaDB and SQLite migrations
Latest
class State
import { State } from "https://dotland.deno.dev/x/nessie@2.0.11/cli/state.ts";

The main state for the application.

Contains the client, and handles the communication to the database.

Constructors

new
State(options: StateOptions)

Properties

client: NessieConfig["client"]
logger: LoggerFn

Methods

private
_fileExistsPrompt(file: string): Promise<boolean>
private
_folderPrompt(folders: string[])
makeMigration(migrationName?)

Makes the migration

makeSeed(seedName?)

Makes the seed

Static Methods

private
_parseMigrationAndSeedFiles(
options: NessieConfig,
migrationFolders: string[],
seedFolders: string[],
)

Parses and sets the migrationFiles and seedFiles

Parses and sets the migrationFolders and seedFolders

Initializes the state with a client