flags

package
v0.8.5 Latest Latest
Warning

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

Go to latest
Published: Nov 15, 2025 License: GPL-3.0 Imports: 1 Imported by: 0

Documentation

Index

Constants

View Source
const (
	// PrivateKeyFlagName is the name of the private key flag.
	PrivateKeyFlagName = "private-key"

	// PrivateKeyFlagUsage is the usage of the private key flag.
	PrivateKeyFlagUsage = "Path to the PEM encoded private key file."

	// PublicKeyFlagName is the name of the public key flag.
	PublicKeyFlagName = "public-key"

	// PublicKeyFlagUsage is the usage of the public key flag.
	PublicKeyFlagUsage = "Path to the PEM encoded public key file."
)

Variables

This section is empty.

Functions

func SetPrivateKeyFlag

func SetPrivateKeyFlag(flag *PrivateKeyFlag)

SetPrivateKeyFlag initializes the private key flag.

Parameters:

  • flag: The PrivateKeyFlag to initialize.

func SetPublicKeyFlag

func SetPublicKeyFlag(flag *PublicKeyFlag)

SetPublicKeyFlag initializes the public key flag.

Parameters:

- flag: The PublicKeyFlag to initialize.

Types

type PrivateKeyFlag

type PrivateKeyFlag struct {
	goflags.Flag
}

PrivateKeyFlag is the name of the private key flag.

func NewPrivateKeyFlag

func NewPrivateKeyFlag(
	defaultValue *string,
) *PrivateKeyFlag

NewPrivateKeyFlag creates a new PrivateKeyFlag.

Parameters:

defaultValue - the default value for the flag.

Returns:

  • A pointer to the created PrivateKeyFlag.

func (*PrivateKeyFlag) Default

func (f *PrivateKeyFlag) Default() string

Default returns the default value of the flag.

Returns:

The default value.

func (*PrivateKeyFlag) Path

func (f *PrivateKeyFlag) Path() string

Path returns the current path value.

Returns:

  • The path as a string.

type PublicKeyFlag

type PublicKeyFlag struct {
	goflags.Flag
}

PublicKeyFlag is the name of the public key flag.

func NewPublicKeyFlag

func NewPublicKeyFlag(
	defaultValue *string,
) *PublicKeyFlag

NewPublicKeyFlag creates a new PublicKeyFlag.

Parameters:

defaultValue - the default value for the flag.

Returns:

  • A pointer to the created PublicKeyFlag.

func (*PublicKeyFlag) Default

func (f *PublicKeyFlag) Default() string

Default returns the default value of the flag.

Returns:

The default value.

func (*PublicKeyFlag) Path

func (f *PublicKeyFlag) Path() string

Path returns the current path value.

Returns:

  • The path as a string.

Jump to

Keyboard shortcuts

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