repo

package
v0.9.0 Latest Latest
Warning

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

Go to latest
Published: May 23, 2021 License: MIT Imports: 15 Imported by: 0

Documentation

Index

Constants

View Source
const (
	// ISO8601 for time format
	ISO8601 = "20060102T150405Z0700"
)

Variables

This section is empty.

Functions

This section is empty.

Types

type Config

type Config struct {
	Provider
	Owner      string
	Name       string
	Token      string
	Endpoint   string
	Artifact   string
	PreRelease bool
}

Config struct

func (Config) String

func (c Config) String() string

String to string for Config

type GithubRelease

type GithubRelease struct {
	// contains filtered or unexported fields
}

GithubRelease struct

func NewGithubRelease

func NewGithubRelease(c Config, d kvs.KVS) *GithubRelease

NewGithubRelease returns GithubRelease

func (*GithubRelease) Fetch

func (g *GithubRelease) Fetch() error

Fetch to latest github release

func (*GithubRelease) GetDeploySourceKey added in v0.7.0

func (g *GithubRelease) GetDeploySourceKey() (string, error)

GetDeploySourceKey returns cache key

func (*GithubRelease) OwnerIconURL

func (g *GithubRelease) OwnerIconURL() string

OwnerIconURL returns owner icon URL

func (*GithubRelease) OwnerURL

func (g *GithubRelease) OwnerURL() string

OwnerURL returns owner URL

func (*GithubRelease) RecordShipping added in v0.7.0

func (g *GithubRelease) RecordShipping() error

RecordShipping save shipping to github

func (*GithubRelease) ReleaseTag

func (g *GithubRelease) ReleaseTag() string

ReleaseTag returns tag

func (*GithubRelease) ReleaseURL

func (g *GithubRelease) ReleaseURL() string

ReleaseURL returns release URL

func (*GithubRelease) String

func (g *GithubRelease) String() string

String to string

func (*GithubRelease) URL

func (g *GithubRelease) URL() string

URL returns repository URL

type Provider

type Provider int

Provider for repository

const (
	// GITHUB repository provider
	GITHUB Provider = iota
)

func (Provider) String

func (r Provider) String() string

String to string for Provider

type Repo

type Repo interface {
	String() string
	Fetch() error
	GetDeploySourceKey() (string, error)
	RecordShipping() error
	ReleaseTag() string
	ReleaseURL() string
	OwnerURL() string
	OwnerIconURL() string
	URL() string
}

Repo interface for repository

func New

func New(c Config, d kvs.KVS) Repo

New returns repo

Jump to

Keyboard shortcuts

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