Documentation ¶
Index ¶
Constants ¶
View Source
const ( // CommandName is the main command's binary name. CommandName = "hugoreleaser" // The prefix used for any flag overrides. EnvPrefix = "HUGORELEASER" // The env file to look for in the current directory. EnvFile = "hugoreleaser.env" )
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type CommandHandler ¶
type Core ¶
type Core struct { // The parsed config. Config config.Config // The common Info logger. InfoLog logg.LevelLogger // The common Warn logger. WarnLog logg.LevelLogger // The common Error logger. ErrorLog logg.LevelLogger // No output to stdout. Quiet bool // Trial run, no builds or releases. Try bool // The Git tag to use for the release. // This tag will eventually be created at release time if it does not exist. Tag string // Paths to build/release. Paths stringFlags PathsBuildsCompiled matchers.Matcher PathsArchivesCompiled matchers.Matcher PathsReleasesCompiled matchers.Matcher // Abolute path to the project root. ProjectDir string // Absolute path to the dist directory. DistDir string // We store builds in ./dist/<project>/<ref>/<DistRootBuilds>/<os>/<arch>/<build DistRootBuilds string // We store archives in ./dist/<project>/<ref>/<DistRootArchives>/<os>/<arch>/<build DistRootArchives string // We store release artifacts in ./dist/<project>/<ref>/<DistRootReleases>/<release.dir> DistRootReleases string // The config file to use. ConfigFile string // Number of parallel tasks. NumWorkers int // Global timeout for all commands. Timeout time.Duration // The global workforce. Workforce *workers.Workforce // Archive plugins started and ready to use. PluginsRegistryArchive map[string]*execrpc.Client[archiveplugin.Request, archiveplugin.Response] }
Core holds common config settings and objects.
func New ¶
New constructs a usable ffcli.Command and an empty Config. The config will be set after a successful parse. The caller must
func (*Core) RegisterFlags ¶
RegisterFlags registers the flag fields into the provided flag.FlagSet. This helper function allows subcommands to register the root flags into their flagsets, creating "global" flags that can be passed after any subcommand at the commandline.
Click to show internal directories.
Click to hide internal directories.