Documentation ¶
Index ¶
Constants ¶
const APPNAME string = "mwcli"
APPNAME to be used throughout the application.
Variables ¶
var MwddIsDevAlias = false
MwddIsDevAlias is the current way to build the mwdd command with the dev alias (may want to clean this up).
var SkipRenderMarkdown = false
SkipRenderMarkdown allows markdown rendering to be skipped in certain situations.
Functions ¶
func CIUserDirectoryPath ¶ added in v0.20.0
func CIUserDirectoryPath() string
func LegacyUserDirectoryPath ¶ added in v0.20.0
func LegacyUserDirectoryPath() string
LegacyUserDirectoryPath is the application configuration directory path for the user determined by legacy method and should be considered deprecated.
func RenderMarkdown ¶
RenderMarkdown converts markdown into something nice to be displayed on the terminal.
func UserDirectoryPath ¶
func UserDirectoryPath() string
UserDirectoryPath is the application configuration directory path for the user.
func UserDirectoryPathForCmd ¶
UserDirectoryPathForCmd is the application configuration directory path for the user for a specific command.
func XDGUserDirectoryPath ¶ added in v0.20.0
func XDGUserDirectoryPath() string
XDGUserDirectoryPath is the application configuration directory path for the user determined by XDG.
Types ¶
type Options ¶
type Options struct { // NoInteraction means commands should not ask for user interaction NoInteraction bool // Verbosity a modifier that can be added to the default logrus level to increase output verbosity. Maximum 2. Verbosity int // Telemetry do we want to record telemetry data? Telemetry bool }
var Opts Options
Options that are global throughout the CLI.
type VersionAttributes ¶
type VersionAttributes struct { GitCommit string // holds short commit hash of source tree. GitBranch string // holds current branch name the code is built off. GitState string // shows whether there are uncommitted changes. GitSummary string // holds output of git describe --tags --dirty --always. BuildDate string // holds RFC3339 formatted UTC date (build time). Version string // hold contents of ./VERSION file, if exists, or the value passed via the -version option. }
var VersionDetails VersionAttributes