Documentation ¶
Index ¶
- func CheckRequirements() error
- func Cmd(image string, vol volume.Volume, opts Options, cmdArgs []string) *exec.Cmd
- func Run(image string, vol volume.Volume, opts Options, cmdArgs []string) error
- func Usage(commands []Command)
- func WindowsResource(ctx Context) (string, error)
- type Android
- type Architecture
- type Command
- type CommonFlags
- type Context
- type Darwin
- type FreeBSD
- type IOS
- type Linux
- type Options
- type Version
- type Windows
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func CheckRequirements ¶
func CheckRequirements() error
CheckRequirements checks if the docker binary is in PATH
func WindowsResource ¶
WindowsResource create a windows resource under the project root that will be automatically linked by compliler during the build
Types ¶
type Android ¶
type Android struct {
Context
}
Android build and package the fyne app for the android OS
func (*Android) Description ¶
Description returns the command description
type Architecture ¶
type Architecture string
Architecture represents the Architecture type
const ( // ArchAmd64 represents the amd64 architecture ArchAmd64 Architecture = "amd64" // Arch386 represents the amd64 architecture Arch386 Architecture = "386" // ArchArm64 represents the arm64 architecture ArchArm64 Architecture = "arm64" // ArchArm represents the arm architecture ArchArm Architecture = "arm" )
func (Architecture) String ¶
func (a Architecture) String() string
type Command ¶
type Command interface { Name() string // Name returns the one word command name Description() string // Description returns the command description Parse(args []string) error // Parse parses the cli arguments Usage() // Usage displays the command usage Run() error // Run runs the command }
Command wraps the methods for a fyne-cross command
type CommonFlags ¶
type CommonFlags struct { // AppID represents the application ID used for distribution AppID string // CacheDir is the directory used to share/cache sources and dependencies. // Default to system cache directory (i.e. $HOME/.cache/fyne-cross) CacheDir string // DockerImage represents a custom docker image to use for build DockerImage string // Env is the list of custom env variable to set. Specified as "KEY=VALUE" Env envFlag // Icon represents the application icon used for distribution Icon string // Ldflags represents the flags to pass to the external linker Ldflags string // Additional build tags Tags tagsFlag // NoCache if true will not use the go build cache NoCache bool // NoStripDebug if true will not strip debug information from binaries NoStripDebug bool // Output represents the named output file Output string // RootDir represents the project root directory RootDir string // Silent enables the silent mode Silent bool // Debug enables the debug mode Debug bool // Pull attempts to pull a newer version of the docker image Pull bool }
CommonFlags holds the flags shared between all commands
type Context ¶
type Context struct { // Volume holds the mounted volumes between host and containers volume.Volume Architecture // Arch defines the target architecture Env []string // Env is the list of custom env variable to set. Specified as "KEY=VALUE" ID string // ID is the context ID LdFlags []string // LdFlags defines the ldflags to use OS string // OS defines the target OS Tags []string // Tags defines the tags to use AppID string // AppID is the appID to use for distribution CacheEnabled bool // CacheEnabled if true enable go build cache DockerImage string // DockerImage defines the docker image used to build Icon string // Icon is the optional icon in png format to use for distribution Output string // Output is the name output Package string // Package is the package to build named by the import path as per 'go build' StripDebug bool // StripDebug if true, strips binary output Debug bool // Debug if true enable debug log Pull bool // Pull if true attempts to pull a newer version of the docker image }
Context represent a build context
type Darwin ¶
type Darwin struct {
Context []Context
}
Darwin build and package the fyne app for the darwin OS
func (*Darwin) Description ¶
Description returns the command description
type FreeBSD ¶
type FreeBSD struct {
Context []Context
}
FreeBSD build and package the fyne app for the freebsd OS
func (*FreeBSD) Description ¶
Description returns the command description
type IOS ¶
type IOS struct {
Context Context
}
IOS build and package the fyne app for the ios OS
func (*IOS) Description ¶
Description returns the command description
type Linux ¶
type Linux struct {
Context []Context
}
Linux build and package the fyne app for the linux OS
func (*Linux) Description ¶
Description returns the command description
type Options ¶
type Options struct { CacheEnabled bool // CacheEnabled if true enable go build cache Env []string // Env is the list of custom env variable to set. Specified as "KEY=VALUE" WorkDir string // WorkDir set the workdir, default to volume's workdir Debug bool // Debug if true enable log verbosity }
Options define the options for the docker run command
type Version ¶
type Version struct{}
Version is the version command
func (*Version) Description ¶
Description returns the command description