migration

package
v0.0.0-...-603ef42 Latest Latest
Warning

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

Go to latest
Published: Dec 9, 2024 License: MIT Imports: 11 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func BOMAwareCSVReader

func BOMAwareCSVReader(reader io.Reader) *csv.Reader

BOMAwareCSVReader will detect a UTF BOM (Byte Order Mark) at the start of the data and transform to UTF8 accordingly. If there is no BOM, it will read the data without any transformation.

This code taken from [this StackOverflow answer](https://stackoverflow.com/a/76023436/558006).

func ExtractOneField

func ExtractOneField(r *csv.Reader, fromCol string) ([]string, error)

func ExtractOneFieldFromFile

func ExtractOneFieldFromFile(path, name string) ([]string, error)

func ImportAndClean

func ImportAndClean(r *csv.Reader, w *csv.Writer) error

Types

This section is empty.

Jump to

Keyboard shortcuts

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