fetcher

package
v0.0.1 Latest Latest
Warning

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

Go to latest
Published: Sep 16, 2025 License: MIT Imports: 11 Imported by: 0

Documentation

Index

Constants

View Source
const (
	FetchedMarkerFile = ".protodex_fetched"
)

Variables

This section is empty.

Functions

This section is empty.

Types

type Fetcher

type Fetcher struct {
	SourceType SourceType
	Source     string
	Version    string
	Dest       string
	// contains filtered or unexported fields
}

func NewFetcher

func NewFetcher(sourceType SourceType, source, version, dest string) (*Fetcher, error)

func NewFetcherFromURL

func NewFetcherFromURL(sourceURL, dest string) (*Fetcher, error)

func (*Fetcher) Fetch

func (f *Fetcher) Fetch() error

type SourceInfo

type SourceInfo struct {
	Type    SourceType
	Source  string // the main identifier (repo, service name, etc.)
	Version string // version, ref, tag, etc.
	Raw     string // original input
}

func ParseSource

func ParseSource(input string) (*SourceInfo, error)

type SourceType

type SourceType string
const (
	SourceGitHub          SourceType = "github"
	SourceHTTP            SourceType = "http"
	SourceGoogleWellKnown SourceType = "google-well-known"
	SourceLocal           SourceType = "local"
	SourceProtodex        SourceType = "protodex"
)

Jump to

Keyboard shortcuts

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