Documentation
¶
Index ¶
- Constants
- Variables
- func CIUserDirectoryPath() string
- func LegacyUserDirectoryPath() string
- func RenderMarkdown(markdownIn string) string
- func UserDirectoryPath() string
- func UserDirectoryPathForCmd(cmdName string) string
- func XDGUserDirectoryPath() string
- type Options
- type Version
- type VersionAttributes
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 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.
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 Version ¶ added in v0.26.1
type Version string
Version string such as "0.10.0". Could also be "latest".
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 Version // hold contents of ./VERSION file, if exists, or the value passed via the -version option. eg. 0.10.0 }
var VersionDetails VersionAttributes