app

package
v0.0.0-...-4ff6035 Latest Latest
Warning

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

Go to latest
Published: Sep 28, 2024 License: MIT Imports: 17 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Authorize

func Authorize(
	ctx context.Context,
	gmailCredentials string,
	tokenFilePath string,
	opener Opener,
	timeout time.Duration,
	port uint,
	baseTransport http.RoundTripper,
	dryRun bool,
) (retErr error)

func GetDefaultTokenPath

func GetDefaultTokenPath() (string, error)

func LogTransport

func LogTransport(logDirPath string, baseTransport http.RoundTripper) http.RoundTripper

func Run

func Run(
	ctx context.Context,
	gmailCredentials string,
	tokenFilePath string,
	measurements []extractor.Measurement,
	baseTransport http.RoundTripper,
	writer io.Writer,
) (retErr error)

func SetupLogger

func SetupLogger()

Types

type Config

type Config struct {
	Measurements []extractor.Measurement `json:"measurements"`
}

func ReadConfig

func ReadConfig(
	path string,
) (_ *Config, retErr error)

type Opener

type Opener interface {
	Open(ctx context.Context, url string) error
}

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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