clipboard

package
v1.15.15 Latest Latest
Warning

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

Go to latest
Published: Nov 24, 2024 License: MIT Imports: 17 Imported by: 30

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	// Helpers can be overridden at compile time, e.g. go build \
	// -ldflags=='-X github.com/gopasspw/gopass/pkg/clipboard.Helpers=termux-api'.
	Helpers = "xsel or xclip"
	// ErrNotSupported is returned when the clipboard is not accessible.
	ErrNotSupported = fmt.Errorf("WARNING: No clipboard available. "+
		"Install %s, provide $GOPASS_CLIPBOARD_COPY_CMD and $GOPASS_CLIPBOARD_CLEAR_CMD or use -f to print to console", Helpers)
)

Functions

func Clear

func Clear(ctx context.Context, name string, checksum string, force bool) error

Clear will attempt to erase the clipboard.

func CopyTo

func CopyTo(ctx context.Context, name string, content []byte, timeout int) error

CopyTo copies the given data to the clipboard and enqueues automatic clearing of the clipboard.

Types

This section is empty.

Jump to

Keyboard shortcuts

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