Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func NewProvisioner ¶
func NewProvisioner(disembedFunc func(string) ([]byte, error), l astikit.StdLogger) astilectron.Provisioner
NewProvisioner builds the proper disembedder provisioner
Types ¶
type Bundler ¶
type Bundler struct {
// contains filtered or unexported fields
}
Bundler represents an object capable of bundling an Astilectron app
func New ¶
func New(c *Configuration, l astikit.StdLogger) (b *Bundler, err error)
New builds a new bundler based on a configuration
func (*Bundler) ClearCache ¶
ClearCache clears the bundler cache
type Configuration ¶
type Configuration struct { // The app name as it should be displayed everywhere // It's also set as an ldflag and therefore accessible in a global var package_name.AppName AppName string `json:"app_name"` // The bind configuration Bind ConfigurationBind `json:"bind"` // Whether the app is a darwin agent app DarwinAgentApp bool `json:"darwin_agent_app"` // List of environments the bundling should be done upon. // An environment is a combination of OS and ARCH Environments []ConfigurationEnvironment `json:"environments"` // The path of the go binary // Defaults to "go" GoBinaryPath string `json:"go_binary_path"` // Paths to icons IconPathDarwin string `json:"icon_path_darwin"` // .icns IconPathLinux string `json:"icon_path_linux"` IconPathWindows string `json:"icon_path_windows"` // .ico // Info.plist property list InfoPlist map[string]interface{} `json:"info_plist"` // The path of the project. // Defaults to the current directory InputPath string `json:"input_path"` // Build flags to pass into go build BuildFlags map[string]string `json:"build_flags"` // LDFlags to pass through to go build LDFlags LDFlags `json:"ldflags"` // The path used for the LD Flags // Defaults to the `Bind.Package` value LDFlagsPackage string `json:"ldflags_package"` // The path to application manifest file (WINDOWS ONLY) ManifestPath string `json:"manifest_path"` // The path where the files will be written // Defaults to "output" OutputPath string `json:"output_path"` // List of commands executed on resources // Paths inside commands must be relative to the resources folder ResourcesAdapters []ConfigurationResourcesAdapter `json:"resources_adapters"` // The path where the resources are/will be created // This path must be relative to the input path // Defaults to "resources" ResourcesPath string `json:"resources_path"` // Show Windows console ShowWindowsConsole bool `json:"show_windows_console"` // The path where the vendor directory will be created // This path must be relative to the output path // Defaults to a temp directory VendorDirPath string `json:"vendor_dir_path"` // Version of Astilectron install VersionAstilectron string `json:"version_astilectron"` // Version of Electron install VersionElectron string `json:"version_electron"` // The path to the working directory. // Defaults to a temp directory WorkingDirectoryPath string `json:"working_directory_path"` //!\\ DEBUG ONLY AstilectronPath string `json:"astilectron_path"` // when making changes to astilectron }
Configuration represents the bundle configuration
type ConfigurationBind ¶
type ConfigurationEnvironment ¶
type ConfigurationEnvironment struct { Arch string `json:"arch"` EnvironmentVariables map[string]string `json:"env"` OS string `json:"os"` }
ConfigurationEnvironment represents the bundle configuration environment
Click to show internal directories.
Click to hide internal directories.