Help us shape the future of Go! Take the 2026 Go Developer Survey

dump

package
v1.7.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Feb 9, 2026 License: Apache-2.0 Imports: 7 Imported by: 0

README

Dump Command

Running Tests

# All dump tests
go test -v ./cmd/dump/

# Specific dump tests
go test -v ./cmd/dump/ -run "TestDumpCommand_Employee"

Documentation

Index

Constants

This section is empty.

Variables

View Source
var DumpCmd = &cobra.Command{
	Use:          "dump",
	Short:        "Dump database schema for a specific schema",
	Long:         "Dump and output database schema information for a specific schema. Uses the --schema flag to target a particular schema (defaults to 'public').",
	RunE:         runDump,
	SilenceUsage: true,
	PreRunE:      util.PreRunEWithEnvVarsAndConnection(&db, &user, &host, &port),
}

Functions

func ExecuteDump

func ExecuteDump(config *DumpConfig) (string, error)

ExecuteDump executes the dump operation with the given configuration

Types

type DumpConfig

type DumpConfig struct {
	Host       string
	Port       int
	DB         string
	User       string
	Password   string
	Schema     string
	MultiFile  bool
	File       string
	NoComments bool
}

DumpConfig holds configuration for dump execution

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL