update

package module
v0.0.0-...-2a5e970 Latest Latest
Warning

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

Go to latest
Published: Oct 6, 2017 License: BSD-3-Clause Imports: 10 Imported by: 2

README

update

Library for self-updating Go programs

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Auto

func Auto(cur Version, url string, check func(Version, string) (Release, error))

Types

type Asset

type Asset struct {
	Name     string `json:"name"`
	Platform string `json:"platform"`
	Url      string `json:"url"`
}

type Release

type Release struct {
	Version Version `json:"version"`
	Assets  []Asset `json:"assets"`
}

func Check

func Check(cur Version, url string) (rel Release, err error)

func CheckGithub

func CheckGithub(cur Version, url string) (rel Release, err error)

func (Release) Install

func (rel Release) Install() error

type Version

type Version struct {
	Major int `json:"major"`
	Minor int `json:"minor"`
	Patch int `json:"patch"`
}

func ParseVersion

func ParseVersion(s string) Version

func (Version) String

func (v Version) String() string

Jump to

Keyboard shortcuts

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