attachments

package
v1.4.1 Latest Latest
Warning

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

Go to latest
Published: Sep 4, 2026 License: MIT Imports: 13 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Destination

func Destination(outputPath, filename string) (string, error)

func PortableFilename

func PortableFilename(filename string) (string, error)

func Save

func Save(ctx context.Context, downloader Downloader, destination, sourceURL string, force bool) (int64, error)

func SaveBytes added in v0.2.0

func SaveBytes(destination string, data []byte, force bool) (int64, error)

SaveBytes safely writes data to destination. Existing paths are preserved unless force is set.

Types

type Downloader

type Downloader interface {
	DownloadBlob(context.Context, string, io.Writer) (int64, http.Header, error)
}

Jump to

Keyboard shortcuts

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