shell_integration

package
v0.2.0 Latest Latest
Warning

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

Go to latest
Published: Dec 31, 2024 License: GPL-3.0 Imports: 17 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var Data = sync.OnceValue(func() Container {
	tr := tar.NewReader(utils.ReaderForCompressedEmbeddedData(embedded_data))
	ans := make(Container, 64)
	for {
		hdr, err := tr.Next()
		if errors.Is(err, io.EOF) {
			break
		}
		if err != nil {
			panic(err)
		}
		data, err := utils.ReadAll(tr, int(hdr.Size))
		if err != nil {
			panic(err)
		}
		ans[hdr.Name] = Entry{hdr, data}
	}
	return ans
})

Functions

func EnsureShellIntegrationFilesFor

func EnsureShellIntegrationFilesFor(shell_name string) (shell_integration_dir_for_shell string, err error)

func EnsureTerminfoFiles

func EnsureTerminfoFiles() (terminfo_dir string, err error)

func IsSupportedShell

func IsSupportedShell(shell_name string) bool

func PathToTerminfoDb

func PathToTerminfoDb(term string) (ans string)

func Setup

func Setup(shell_name string, ksi_var string, argv []string, env map[string]string) ([]string, map[string]string, error)

func TerminfoData

func TerminfoData() string

Types

type Container

type Container map[string]Entry

func (Container) FilesMatching

func (self Container) FilesMatching(prefix string, exclude_patterns ...string) []string

type Entry

type Entry struct {
	Metadata *tar.Header
	Data     []byte
}

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL
JackTT - Gopher 🇻🇳