alkasir: Index | Files

package nexus

import ""

Package nexus - artifacts query stuff for releases, this whole package should probably be moved out of Alkasir.


Package Files

artifact.go artifacts.go buildquery.go doc.go nexus.go util.go

func GetMasterSnapshot Uses

func GetMasterSnapshot(cmd string) error

Quickrunner for the latest archived release

func QuickReleaseRunner Uses

func QuickReleaseRunner(cmd string)

Quickrunner for the latest archived release

type Artifact Uses

type Artifact struct {
    // contains filtered or unexported fields

Artifact combines nexus artifact with semver features

func (*Artifact) Binaries Uses

func (a *Artifact) Binaries() []string

Binaries returns a list of patjhs to binaries

func (*Artifact) Dir Uses

func (a *Artifact) Dir(ns string) string

func (*Artifact) Download Uses

func (a *Artifact) Download() error

Download downloads the artifact to a local directory

func (*Artifact) Equal Uses

func (a *Artifact) Equal(b *Artifact) bool

Equal compares the semver version number, nothing else.

func (*Artifact) Extract Uses

func (a *Artifact) Extract() error

func (*Artifact) GlobPath Uses

func (a *Artifact) GlobPath(cmdglob string) ([]string, error)

func (*Artifact) GreaterThan Uses

func (a *Artifact) GreaterThan(b *Artifact) bool

GreaterThan compares the semver version number

func (*Artifact) Info Uses

func (a *Artifact) Info() *nexus.ArtifactInfo

func (*Artifact) LessThan Uses

func (a *Artifact) LessThan(b *Artifact) bool

LessThan compares the semver version number

func (*Artifact) LinkBinaries Uses

func (a *Artifact) LinkBinaries() error

LinkBinaries links any binaries from an extracted archive path to PWD.

func (*Artifact) Path Uses

func (a *Artifact) Path() string

Path returns the path to the downloaded artifact

func (*Artifact) Run Uses

func (a *Artifact) Run(cmdglob string) error

type Artifacts Uses

type Artifacts []*Artifact

Artifacts is a collection of artifacts, sortable with utiltity functions.

func (Artifacts) Latest Uses

func (a Artifacts) Latest() *Artifact

Latest resurns the latest version number in the list.

func (Artifacts) Len Uses

func (v Artifacts) Len() int

Len is implemnting sort.Interface

func (Artifacts) Less Uses

func (v Artifacts) Less(i, j int) bool

Less is implementing sort.Interface

func (Artifacts) Swap Uses

func (v Artifacts) Swap(i, j int)

Swap is implementing sort.Interface

type BuildQuery Uses

type BuildQuery struct {
    OS      string // target os.
    Arch    string // target arch.
    Cmd     string // target cmd, builds cmd/[cmd]/[cmd].go.
    Version string // version number.

BuildQuery contains all configuration for a building a go cmd

func (*BuildQuery) ArtifactDisplayName Uses

func (b *BuildQuery) ArtifactDisplayName() string

ArtifactID constructs a cmd-os-arch string

func (*BuildQuery) Classifier Uses

func (b *BuildQuery) Classifier() string

Classifier constructs a os-arch string

func (*BuildQuery) GetBinary Uses

func (q *BuildQuery) GetBinary(artifact *Artifact) (string, error)

GetBinary downloads artifact, extracts archive and returns the path to the extracted executable. If the file already exits it is not downloaded.

func (*BuildQuery) GetMatchingBuildBinary Uses

func (q *BuildQuery) GetMatchingBuildBinary() (string, error)

Quickrunner for the latest archived release

func (*BuildQuery) GetVersions Uses

func (b *BuildQuery) GetVersions() (Artifacts, error)

Package nexus imports 18 packages (graph) and is imported by 2 packages. Updated 2016-07-24. Refresh now. Tools for package owners.