代码拉取完成,页面将自动刷新
package main
import (
"flag"
"strings"
)
type arguments struct {
CwdMode *string
CwdMaxDepth *int
CwdMaxDirSize *int
ColorizeHostname *bool
HostnameOnlyIfSSH *bool
SshAlternateIcon *bool
EastAsianWidth *bool
PromptOnNewLine *bool
StaticPromptIndicator *bool
VenvNameSizeLimit *int
GitAssumeUnchangedSize *int64
GitDisableStats *string
GitMode *string
Jobs *int
Mode *string
Theme *string
Shell *string
Modules *string
ModulesRight *string
Priority *string
MaxWidthPercentage *int
TruncateSegmentWidth *int
PrevError *int
NumericExitCodes *bool
IgnoreRepos *string
ShortenGKENames *bool
ShortenEKSNames *bool
ShellVar *string
ShellVarNoWarnEmpty *bool
TrimADDomain *bool
PathAliases *string
Duration *string
DurationMin *string
Eval *bool
Condensed *bool
IgnoreWarnings *bool
}
var args = arguments{
CwdMode: flag.String(
"cwd-mode",
defaults.CwdMode,
commentsWithDefaults("How to display the current directory",
"(valid choices: fancy, semifancy, plain, dironly)")),
CwdMaxDepth: flag.Int(
"cwd-max-depth",
defaults.CwdMaxDepth,
commentsWithDefaults("Maximum number of directories to show in path")),
CwdMaxDirSize: flag.Int(
"cwd-max-dir-size",
defaults.CwdMaxDirSize,
commentsWithDefaults("Maximum number of letters displayed for each directory in the path")),
ColorizeHostname: flag.Bool(
"colorize-hostname",
defaults.ColorizeHostname,
comments("Colorize the hostname based on a hash of itself, or use the PLGO_HOSTNAMEFG and/or PLGO_HOSTNAMEBG env vars.")),
HostnameOnlyIfSSH: flag.Bool(
"hostname-only-if-ssh",
defaults.HostnameOnlyIfSSH,
comments("Show hostname only for SSH connections")),
SshAlternateIcon: flag.Bool(
"alternate-ssh-icon",
defaults.SshAlternateIcon,
comments("Show the older, original icon for SSH connections")),
EastAsianWidth: flag.Bool(
"east-asian-width",
defaults.EastAsianWidth,
comments("Use East Asian Ambiguous Widths")),
PromptOnNewLine: flag.Bool(
"newline",
defaults.PromptOnNewLine,
comments("Show the prompt on a new line")),
StaticPromptIndicator: flag.Bool(
"static-prompt-indicator",
defaults.StaticPromptIndicator,
comments("Always show the prompt indicator with the default color, never with the error color")),
VenvNameSizeLimit: flag.Int(
"venv-name-size-limit",
defaults.VenvNameSizeLimit,
comments("Show indicator instead of virtualenv name if name is longer than this limit (defaults to 0, which is unlimited)")),
Jobs: flag.Int(
"jobs",
defaults.Jobs,
comments("Number of jobs currently running")),
GitAssumeUnchangedSize: flag.Int64(
"git-assume-unchanged-size",
defaults.GitAssumeUnchangedSize,
comments("Disable checking for changed/edited files in git repositories where the index is larger than this size (in KB), improves performance")),
GitDisableStats: flag.String(
"git-disable-stats",
strings.Join(defaults.GitDisableStats, ","),
commentsWithDefaults("Comma-separated list to disable individual git statuses",
"(valid choices: ahead, behind, staged, notStaged, untracked, conflicted, stashed)")),
GitMode: flag.String(
"git-mode",
defaults.GitMode,
commentsWithDefaults("How to display git status",
"(valid choices: fancy, simple)")),
Mode: flag.String(
"mode",
defaults.Mode,
commentsWithDefaults("The characters used to make separators between segments.",
"(valid choices: patched, compatible, flat)")),
Theme: flag.String(
"theme",
defaults.Theme,
commentsWithDefaults("Set this to the theme you want to use",
"(valid choices: default, low-contrast)")),
Shell: flag.String(
"shell",
defaults.Shell,
commentsWithDefaults("Set this to your shell type",
"(valid choices: autodetect, bare, bash, zsh)")),
Modules: flag.String(
"modules",
strings.Join(defaults.Modules, ","),
commentsWithDefaults("The list of modules to load, separated by ','",
"(valid choices: aws, cwd, docker, docker-context, dotenv, duration, exit, git, gitlite, goenv, hg, host, jobs, kube, load, newline, nix-shell, node, perlbrew, perms, plenv, root, shell-var, shenv, ssh, svn, termtitle, terraform-workspace, time, user, venv, vgo)",
"Unrecognized modules will be invoked as 'powerline-go-MODULE' executable plugins and should output a (possibly empty) list of JSON objects that unmarshal to powerline-go's Segment structs.")),
ModulesRight: flag.String(
"modules-right",
strings.Join(defaults.ModulesRight, ","),
comments("The list of modules to load anchored to the right, for shells that support it, separated by ','",
"(valid choices: aws, cwd, docker, docker-context, dotenv, duration, exit, git, gitlite, goenv, hg, host, jobs, kube, load, newline, nix-shell, node, perlbrew, perms, plenv, root, shell-var, shenv, ssh, svn, termtitle, terraform-workspace, time, user, venv, vgo)",
"Unrecognized modules will be invoked as 'powerline-go-MODULE' executable plugins and should output a (possibly empty) list of JSON objects that unmarshal to powerline-go's Segment structs.")),
Priority: flag.String(
"priority",
strings.Join(defaults.Priority, ","),
commentsWithDefaults("Segments sorted by priority, if not enough space exists, the least priorized segments are removed first. Separate with ','",
"(valid choices: aws, cwd, docker, docker-context, dotenv, duration, exit, git, gitlite, hg, host, jobs, kube, load, newline, nix-shell, node, perlbrew, perms, plenv, root, shell-var, shenv, ssh, svn, termtitle, terraform-workspace, time, user, venv, vgo)")),
MaxWidthPercentage: flag.Int(
"max-width",
defaults.MaxWidthPercentage,
comments("Maximum width of the shell that the prompt may use, in percent. Setting this to 0 disables the shrinking subsystem.")),
TruncateSegmentWidth: flag.Int(
"truncate-segment-width",
defaults.TruncateSegmentWidth,
commentsWithDefaults("Maximum width of a segment, segments longer than this will be shortened if space is limited. Setting this to 0 disables it.")),
PrevError: flag.Int(
"error",
defaults.PrevError,
comments("Exit code of previously executed command")),
NumericExitCodes: flag.Bool(
"numeric-exit-codes",
defaults.NumericExitCodes,
comments("Shows numeric exit codes for errors.")),
IgnoreRepos: flag.String(
"ignore-repos",
strings.Join(defaults.IgnoreRepos, ","),
comments("A list of git repos to ignore. Separate with ','.",
"Repos are identified by their root directory.")),
ShortenGKENames: flag.Bool(
"shorten-gke-names",
defaults.ShortenGKENames,
comments("Shortens names for GKE Kube clusters.")),
ShortenEKSNames: flag.Bool(
"shorten-eks-names",
defaults.ShortenEKSNames,
comments("Shortens names for EKS Kube clusters.")),
ShellVar: flag.String(
"shell-var",
defaults.ShellVar,
comments("A shell variable to add to the segments.")),
ShellVarNoWarnEmpty: flag.Bool(
"shell-var-no-warn-empty",
defaults.ShellVarNoWarnEmpty,
comments("Disables warning for empty shell variable.")),
TrimADDomain: flag.Bool(
"trim-ad-domain",
defaults.TrimADDomain,
comments("Trim the Domainname from the AD username.")),
PathAliases: flag.String(
"path-aliases",
"",
comments("One or more aliases from a path to a short name. Separate with ','.",
"An alias maps a path like foo/bar/baz to a short name like FBB.",
"Specify these as key/value pairs like foo/bar/baz=FBB.",
"Use '~' for your home dir. You may need to escape this character to avoid shell substitution.")),
Duration: flag.String(
"duration",
defaults.Duration,
comments("The elapsed clock-time of the previous command")),
DurationMin: flag.String(
"duration-min",
defaults.DurationMin,
comments("The minimal time a command has to take before the duration segment is shown")),
Eval: flag.Bool(
"eval",
defaults.Eval,
comments("Output prompt in 'eval' format.")),
Condensed: flag.Bool(
"condensed",
defaults.Condensed,
comments("Remove spacing between segments")),
IgnoreWarnings: flag.Bool(
"ignore-warnings",
defaults.IgnoreWarnings,
comments("Ignores all warnings regarding unset or broken variables")),
}
此处可能存在不合适展示的内容,页面不予展示。您可通过相关编辑功能自查并修改。
如您确认内容无涉及 不当用语 / 纯广告导流 / 暴力 / 低俗色情 / 侵权 / 盗版 / 虚假 / 无价值内容或违法国家有关法律法规的内容,可点击提交进行申诉,我们将尽快为您处理。