file

package
v0.0.0-...-c17dd75 Latest Latest
Warning

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

Go to latest
Published: Oct 5, 2021 License: MIT Imports: 5 Imported by: 1

Documentation

Overview

Package file provides source.Driver for local file system.

Example
wd, err := os.Getwd()
if err != nil {
	panic(err)
}
sourceURL := "file://" + path.Join(wd, "testdata")
println(sourceURL)
m, err := migrate.New(sourceURL, "stub://")
if err != nil {
	panic(err)
}
_ = m
// m.Up()
Output:

Index

Examples

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type File

type File struct {
	iofs.PartialDriver
	// contains filtered or unexported fields
}

File is a source.Driver that reads from local file system.

func (*File) Open

func (f *File) Open(url string) (source.Driver, error)

Open implements source.Driver. Tha path must be relative.

Jump to

Keyboard shortcuts

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