Documentation
¶
Index ¶
- type ChocoSpec
- type WixEnv
- type WixEnvList
- type WixFiles
- type WixManifest
- func (wixFile *WixManifest) Load(p string) error
- func (wixFile *WixManifest) NeedGUID() bool
- func (wixFile *WixManifest) Normalize() error
- func (wixFile *WixManifest) RewriteFilePaths(out string) error
- func (wixFile *WixManifest) SetGuids() (bool, error)
- func (wixFile *WixManifest) Write(p string) error
- type WixShortcut
- type WixShortcuts
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type ChocoSpec ¶
type ChocoSpec struct {
ID string `json:"id,omitempty"`
Title string `json:"title,omitempty"`
Authors string `json:"authors,omitempty"`
Owners string `json:"owners,omitempty"`
Description string `json:"description,omitempty"`
ProjectURL string `json:"project-url,omitempty"`
Tags string `json:"tags,omitempty"`
LicenseURL string `json:"license-url,omitempty"`
IconURL string `json:"icon-url,omitempty"`
RequireLicense bool `json:"require-license,omitempty"`
MsiFile string `json:"-"`
MsiSum string `json:"-"`
BuildDir string `json:"-"`
ChangeLog string `json:"-"`
}
ChocoSpec is the struct to decode the choco key of a wix.json file.
type WixEnv ¶
type WixEnv struct {
Name string `json:"name"`
Value string `json:"value"`
Permanent string `json:"permanent"`
System string `json:"system"`
Action string `json:"action"`
Part string `json:"part"`
}
WixEnv is the struct to decode env value of the wix.json file.
type WixEnvList ¶
WixEnvList is the struct to decode env key of the wix.json file.
type WixManifest ¶
type WixManifest struct {
Product string `json:"product"`
Company string `json:"company"`
Version string `json:"version,omitempty"`
VersionOk string `json:"-"`
License string `json:"license,omitempty"`
UpgradeCode string `json:"upgrade-code"`
Files WixFiles `json:"files,omitempty"`
Directories []string `json:"directories,omitempty"`
RelDirs []string `json:"-"`
Env WixEnvList `json:"env,omitempty"`
Shortcuts WixShortcuts `json:"shortcuts,omitempty"`
Choco ChocoSpec `json:"choco,omitempty"`
}
WixManifest is the struct to decode a wix.json file.
func (*WixManifest) Load ¶
func (wixFile *WixManifest) Load(p string) error
Load the manifest from given file path, if the file path is empty, reads from wix.json
func (*WixManifest) NeedGUID ¶
func (wixFile *WixManifest) NeedGUID() bool
NeedGUID tells if the manifest json file is missing guid values.
func (*WixManifest) Normalize ¶
func (wixFile *WixManifest) Normalize() error
Normalize Appropriately fixes some values within the decoded json It applies defaults values on the wix/msi property to to generate the msi package. It applies defaults values on the choco property to generate a nuget package
func (*WixManifest) RewriteFilePaths ¶
func (wixFile *WixManifest) RewriteFilePaths(out string) error
RewriteFilePaths Reads Files and Directories of the wix.json file and turn their values into a relative path to out where out is the path to the wix templates files.
func (*WixManifest) SetGuids ¶
func (wixFile *WixManifest) SetGuids() (bool, error)
SetGuids generates and apply guid values appropriately
func (*WixManifest) Write ¶
func (wixFile *WixManifest) Write(p string) error
Write the manifest to the given file, if file is empty, writes to wix.json
type WixShortcut ¶
type WixShortcut struct {
Name string `json:"name"`
Description string `json:"description"`
Target string `json:"target"`
WDir string `json:"wdir"`
Arguments string `json:"arguments"`
Icon string `json:"icon"` // a path to the ico file, no space in it.
}
WixShortcut is the struct to decode shortcut value of the wix.json file.
type WixShortcuts ¶
type WixShortcuts struct {
GUID string `json:"guid,omitempty"`
Items []WixShortcut `json:"items,omitempty"`
}
WixShortcuts is the struct to decode shortcuts key of the wix.json file.