commands

package
v5.0.3+incompatible Latest Latest
Warning

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

Go to latest
Published: Mar 16, 2018 License: Apache-2.0 Imports: 23 Imported by: 0

Documentation

Index

Constants

View Source
const AdminUserId = 1

Variables

View Source
var Commands = []cli.Command{
	{
		Name:        "plugins",
		Usage:       "Manage plugins for grafana",
		Subcommands: pluginCommands,
	},
	{
		Name:        "admin",
		Usage:       "Grafana admin commands",
		Subcommands: adminCommands,
	},
}

Functions

func InstallPlugin

func InstallPlugin(pluginName, version string, c CommandLine) error

func PermissionsError

func PermissionsError(err error) bool

func RemoveGitBuildFromName

func RemoveGitBuildFromName(pluginName, filename string) string

func SelectVersion

func SelectVersion(plugin m.Plugin, version string) (m.Version, error)

func ShouldUpgrade

func ShouldUpgrade(installed string, remote m.Plugin) bool

Types

type CommandLine

type CommandLine interface {
	ShowHelp()
	ShowVersion()
	Application() *cli.App
	Args() cli.Args
	Bool(name string) bool
	Int(name string) int
	String(name string) string
	StringSlice(name string) []string
	GlobalString(name string) string
	FlagNames() (names []string)
	Generic(name string) interface{}

	PluginDirectory() string
	RepoDirectory() string
	PluginURL() string
}

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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