cmd

package
v0.0.0-...-88bc37c Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Oct 9, 2018 License: GPL-3.0 Imports: 8 Imported by: 0

Documentation

Index

Constants

View Source
const DefaultTimestampFormat = "2006-01-02 15:04:05"

Variables

View Source
var (
	Version   string
	Sha       string
	Builddate string
	Goversion string
)

Build time constant variables from -ldflags

View Source
var VersionCmd = &cobra.Command{
	Use:   "version",
	Short: "Show version",
	Long:  "Show version",
	Run: func(cmd *cobra.Command, args []string) {
		fmt.Printf("%s version %s (git: %s, build: %s, goversion: %s)\n",
			cmd.Root().CommandPath(),
			Version,
			Sha[:8],
			Builddate,
			Goversion,
		)
	},
}

Functions

This section is empty.

Types

type LogFormatter

type LogFormatter struct {
	DisableTimestamp  bool
	DisableStacktrace bool
	DisableFileLine   bool
}

func (*LogFormatter) Format

func (f *LogFormatter) Format(entry *logrus.Entry) ([]byte, error)

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL