go-utils/updater/client.go

29 lines
497 B
Go
Raw Normal View History

2021-08-14 20:28:50 +00:00
package updater
import "time"
type Client struct {
// GitHub repo with author e.g. "MedzikUser/go-utils"
GitHub string
// GitHub Token
GitHubToken string
2021-08-14 20:28:50 +00:00
// Application version e.g. "2.15.43"
Version string
// Binary name in archive e.g. "utils.out"
Binary string
// Check latest version every
CheckEvery time.Duration
/*
After update exec function e.g.
func() {
os.Exit(0)
}
*/
AfterUpdate func()
// Update Rules
2021-08-22 10:16:39 +00:00
// Should I update the major? (X.y.z)
Major bool
2021-08-14 20:28:50 +00:00
}