Documentation
¶
Index ¶
- func Configure(consumer *state.Consumer, installFolder string, runtime ox.Runtime) (*dash.Verdict, error)
- func ExclusivityScore(p itchio.Platforms) int64
- func IsCompatible(p itchio.Platforms, rt ox.Runtime) bool
- type ClassificationAction
- type Host
- type HostEnumerator
- type Hosts
- type NarrowDownUploadsResult
- type Wrapper
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func ExclusivityScore ¶
ExclusivityScore returns a higher value the closest an upload is to being *only for this platform*
Types ¶
type ClassificationAction ¶
type ClassificationAction string
const ( ClassificationActionOpen ClassificationAction = "open" ClassificationActionLaunch ClassificationAction = "launch" )
type Host ¶
type Host struct {
// os + arch, e.g. windows-i386, linux-amd64
Runtime ox.Runtime `json:"runtime"`
// wrapper tool (wine, etc.) that butler can launch itself
Wrapper *Wrapper `json:"wrapper,omitempty"`
RemoteLaunchName string `json:"remoteLaunchName,omitempty"`
}
func NativeHost ¶
func NativeHost() Host
type HostEnumerator ¶
type HostEnumerator interface {
// Returns a list of supported hosts, from most preferred
// to least preferred
Enumerate(consumer *state.Consumer) (Hosts, error)
}
func DefaultHostEnumerator ¶
func DefaultHostEnumerator() HostEnumerator
func SingleHostEnumerator ¶
func SingleHostEnumerator(rt ox.Runtime) HostEnumerator
type NarrowDownUploadsResult ¶
type NarrowDownUploadsResult struct {
InitialUploads []*itchio.Upload
Uploads []*itchio.Upload
HadWrongFormat bool
HadWrongArch bool
}
func NarrowDownUploads ¶
func NarrowDownUploads(consumer *state.Consumer, game *itchio.Game, uploads []*itchio.Upload, runtimeEnum HostEnumerator) (*NarrowDownUploadsResult, error)
type Wrapper ¶
type Wrapper struct {
// wrapper {HERE} game.exe --launch-editor
BeforeTarget []string `json:"beforeTarget"`
// wrapper game.exe {HERE} --launch-editor
BetweenTargetAndArgs []string `json:"betweenTargetAndArgs"`
// wrapper game.exe --launch-editor {HERE}
AfterArgs []string `json:"afterArgs"`
// full path to the wrapper, like "wine"
WrapperBinary string `json:"wrapperBinary"`
// additional environment variables
Env map[string]string `json:"env"`
// When this is true, the wrapper can't function like this:
//
// $ wine /path/to/game.exe
//
// It needs to function like this:
//
// $ cd /path/to
// $ wine game.exe
//
// This is at least true for wine, which cannot find required DLLs
// otherwise. This might be true for other wrappers, so it's an option here.
NeedRelativeTarget bool `json:"needRelativeTarget"`
}
Source Files
¶
Click to show internal directories.
Click to hide internal directories.