Documentation ¶
Overview ¶
Package packer handles the process of packaging asset with the support of supporting library.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type PackkerInput ¶
type PackkerInput struct { // The name of the asset client stub. Name string `json:"name" yaml:"name"` // TempPath would be used to carryout all the operation of Unpackker defaults to PWD. TempPath string `json:"tempath" yaml:"tempath"` // Path to asset which has to be packed. AssetPath string `json:"assetpath" yaml:"assetpath" env:"UNPACKKER_ASSET_PATH"` // AssetMetaData is set of metadata that has to be applied to the asset. // This value can be used while unpacking or for any future requirements. AssetMetaData map[string]string `json:"assetmetadata" yaml:"assetmetadata"` // Path defines where the packed asset has to be placed. Path string `json:"path" yaml:"path"` // IgnoreFiles are regexes of the files that should be avided. IgnoreFiles []string `json:"ignore" yaml:"ignore"` // Environment in which the asset is packed. Environment string `json:"environment" yaml:"environment" env:"UNPACKKER_ENVIRONMENT"` // AssetVersion refers to version of asset which has to eb packed. AssetVersion string `json:"assetversion" yaml:"assetversion" env:"UNPACKKER_ASSET_VERSION"` // Backend for the asset generated. Backend *backend.Store `json:"backend" yaml:"backend"` // ConfigPath refers to file path where the config file lies, defaults to PWD. ConfigPath string `json:"configpath" yaml:"configpath" env:"UNPACKKER_CONFIG_PATH"` // CleanLocalCache clears the local cache creted under PackkerInput.Path if enabled, // this will be effective only if backend is type 'fs'. CleanLocalCache bool `json:"cleancache" yaml:"cleancache" env:"UNPACKKER_CLEAN_LOCALCACHE"` gen.GenInput // contains filtered or unexported fields }
PackkerInput holds the required fields to pack the asset.
func (*PackkerInput) LoadConfig ¶
func (i *PackkerInput) LoadConfig() (*PackkerInput, error)
LoadConfig will load config from file `unpackker-config` onto PackkerInput.
Click to show internal directories.
Click to hide internal directories.