hilbiline

package module
v0.0.0-...-f1b20c1 Latest Latest
Warning

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

Go to latest
Published: Apr 16, 2021 License: BSD-3-Clause Imports: 6 Imported by: 0

README

Hilbiline

A readline-inspired line editor made for Hilbish

Hilbiline is the custom made line editor for the Hilbi Shell

License

Hilbiline is licensed under the BSD 3-clause license. Read here for more info

Documentation

Index

Constants

View Source
const (
	// Keycodes
	KeyNull      = 0
	KeyCtrlA     = 1
	KeyCtrlB     = 2
	KeyCtrlC     = 3
	KeyCtrlD     = 4
	KeyCtrlE     = 5
	KeyCtrlF     = 6
	KeyCtrlH     = 8
	KeyTab       = 9
	KeyCtrlJ     = 10
	KeyCtrlK     = 11
	KeyCtrlL     = 12
	KeyEnter     = 13
	KeyCtrlN     = 14
	KeyCtrlP     = 16
	KeyCtrlT     = 20
	KeyCtrlU     = 21
	KeyCtrlW     = 23
	KeyEsc       = 27
	KeyBackspace = 127
)

Variables

View Source
var (
	HistoryMaxLen = 1000
)

Functions

This section is empty.

Types

type HilbilineState

type HilbilineState struct {
	// contains filtered or unexported fields
}

func New

func New(prompt string) HilbilineState

func (HilbilineState) ClearScreen

func (h HilbilineState) ClearScreen()

func (HilbilineState) LoadHistory

func (h HilbilineState) LoadHistory(path string) error

func (HilbilineState) PrintPrompt

func (h HilbilineState) PrintPrompt()

func (*HilbilineState) Read

func (h *HilbilineState) Read() (string, error)

func (*HilbilineState) SetPrompt

func (h *HilbilineState) SetPrompt(prompt string)

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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