tuitest
Headless testing harness for terminal programs: real PTY, VT emulator, deterministic waits, and golden screen snapshots
File Explorer
- main.go
- banner.png
- fuzz.gif
- hero.gif
- run.gif
- snap.gif
- social-preview.png
- api.md
- architecture.md
- cli.md
- extending.md
- fuzzing.md
- input-protocols.md
- limits.md
- tape.md
- control_plane_test.go
- stress_test.go
- tuios_test.go
- fakeshell.go
- shrink.go
- vtgen.go
- vtgen_test.go
- corpus.go
- detect.go
- detect_test.go
- fuzz.go
- fuzz_test.go
- gen.go
- hostile.go
- oracle_e2e_test.go
- oracle_test.go
- rss_linux.go
- rss_other.go
- shrink.go
- shrink_test.go
- cli.go
- cli_test.go
- diagnostics.go
- doctor.go
- errors.go
- flags.go
- fuzz.go
- help_verbs_test.go
- record.go
- record_test.go
- replay.go
- resize_unix.go
- resize_windows.go
- run.go
- snap.go
- emu.go
- proctree_unix.go
- proctree_unix_test.go
- ptyproc.go
- ptyproc_test.go
- ptyproc_unix.go
- ptyproc_windows.go
- termios_tcgets.go
- termios_tiocgeta.go
- textdist.go
- ce2d19415072e0e1
- 59a91c98a847cf8d
- bounds_test.go
- bufpipe.go
- callbacks.go
- cc.go
- charset.go
- csi.go
- csi_cursor.go
- csi_mode.go
- csi_screen.go
- csi_sgr.go
- cursor.go
- dcs.go
- DIVERGENCE
- doc.go
- emulator.go
- emulator_test.go
- esc.go
- fidelity_test.go
- focus.go
- handlers.go
- key.go
- kitty_handlers.go
- kitty_keyboard.go
- kitty_parser.go
- kitty_shm_unix.go
- kitty_shm_windows.go
- kitty_state.go
- kitty_types.go
- margins_test.go
- mode.go
- mouse.go
- osc.go
- query_test.go
- screen.go
- scrollback.go
- semantic_markers.go
- sixel_parser.go
- sixel_state.go
- UPSTREAM
- utf8.go
- utils.go
- VENDOR.md
- vendor_test.go
- vt.go
- vtgen_fuzz_test.go
- tuitest.json
- turbograph.json
- vtgl.json
- webterm.json
- make-banner.mjs
- motifs.mjs
- README.md
- hero.tape
- readme-stale.tape
- readme.tape
- common.tape
- fuzz.tape
- hero-session.sh
- hero.tape
- README.md
- record-replay.tape
- record.sh
- run.tape
- snap.tape
- dump.mjs
- gencorpus.py
- README.md
- record.py
- vendor-vt.sh
- da75988793b97b36
- 1e4f3ef2fbdff505
- 24173d7ce7d798ea
- 51a6fa6af9e07675
- 5f4c5386574ff891
- 8643a79bab153d1b
- d24ac4ca7d9b4766
- d544b1faf946a362
- legacy-press-with-no-button
- 03be21c37a4b4282
- 0f506853ad41d3d8
- 1868605049bbda46
- 3fffd24c2e470d7a
- 4de25dada08f0cba
- 57b6b309cb124a7d
- 7c54a3625d4cb722
- 97c2992114fe31b1
- bare-type-verb
- huge-size
- min-int64-sleep
- regex-trailing-slash
- regex-with-slash-and-space
- type-trailing-cr
- wait-stable-with-timeout
- 0c2e7acd6582f28f
- 1f4957f20dad7579
- 347792c18fb22686
- d05a0220778773e9
- meta-invalid-utf8
- meta-plus-has-no-chord-spelling
- mouse-leading-zero-parameter
- 45bf470823a1f5aa
- 95f9167e6834c9d1
- adf5fed6fae387a2
- ctrl-no-base
- repeated-alt
- shift-no-base
- 55baab770df20ce0
- meta-space-breaks-the-tokenizer
- apc_test.go
- assertion_test.go
- closestline_test.go
- csiparams.go
- decode.go
- decode_bench_test.go
- decode_boundary_test.go
- decode_test.go
- errors.go
- extensibility_test.go
- framer.go
- fuzz_test.go
- input_fuzz_test.go
- keyattrs.go
- keys.go
- keytable.go
- lossless_test.go
- parse.go
- parse_position_test.go
- parse_test.go
- parse_verbs_test.go
- player.go
- player_test.go
- print.go
- print_roundtrip_test.go
- print_verbs_test.go
- proto_capture_test.go
- proto_evidence_test.go
- proto_focus.go
- proto_fuzz_test.go
- proto_keyboard_test.go
- proto_kitty.go
- proto_legacy.go
- proto_modifyother.go
- proto_mouse.go
- proto_paste.go
- proto_test.go
- protocol.go
- record.go
- record_test.go
- replay.go
- replay_test.go
- roundtrip_test.go
- session.go
- main.go
- main.go
- blank-lines-vs-empty
- marker-lookalike
- reversed
- many-sgr-params
- osc133-cycle
- resize-request
- every-attribute
- full-grid-defaults
- run-touching-last-column
- styled-full-row
- wide-and-continuation
- main.go
- absurd_params.vt
- absurd_scroll_region.vt
- alt_1047.vt
- alt_1047_back.vt
- alt_1048.vt
- alt_1049.vt
- alt_1049_back.vt
- alt_1049_cursor.vt
- alt_47.vt
- alt_scroll_isolated.vt
- autowrap_off.vt
- autowrap_on.vt
- bracketed_paste.vt
- bs_at_col0.vt
- c1_controls.vt
- charset_dec_special.vt
- charset_g1_so.vt
- charset_scs_g2.vt
- combining.vt
- cr_lf_ff_vt.vt
- cup_missing_params.vt
- cursor_clamp.vt
- cursor_moves.vt
- cursor_visibility.vt
- decaln.vt
- decdwl.vt
- decsc_decrc.vt
- decsc_keeps_sgr.vt
- decsc_origin.vt
- decsed_decsel.vt
- decstr.vt
- ech.vt
- ech_huge.vt
- ed_1.vt
- ed_2.vt
- ed_3.vt
- ed_modes.vt
- el_modes.vt
- emoji.vt
- erase_keeps_bg.vt
- hpr_vpr.vt
- ich_dch.vt
- ich_dch_huge.vt
- il_dl.vt
- il_dl_in_region.vt
- il_outside_region.vt
- invalid_utf8.vt
- invalid_utf8_marker.vt
- irm_insert.vt
- lnm.vt
- mouse_modes.vt
- nul_and_del.vt
- origin_mode.vt
- origin_mode_off.vt
- pending_wrap_cr.vt
- powerline.vt
- prog_btop.vt
- prog_fish.vt
- prog_htop.vt
- prog_less.vt
- prog_tmux.vt
- prog_vim.vt
- reverse_wrap.vt
- ris.vt
- sco_save_restore.vt
- scroll_region_basic.vt
- scroll_region_full_su.vt
- scroll_region_lr.vt
- scroll_region_reset.vt
- scroll_region_ri.vt
- scroll_region_su_sd.vt
- sgr_256.vt
- sgr_basic.vt
- sgr_colors.vt
- sgr_default_colors.vt
- sgr_empty_params.vt
- sgr_faint.vt
- sgr_reset_pairs.vt
- sgr_rgb.vt
- sgr_rgb_colon.vt
- sgr_underline_styles.vt
- tabs_cbt.vt
- tabs_cht.vt
- tabs_default.vt
- tabs_set_clear.vt
- tabs_tbc3.vt
- truncated_seqs.vt
- unknown_csi.vt
- utf8_split_safe.vt
- utf8_truncated_tail.vt
- wide_overwrite.vt
- wide_runes.vt
- wrap_then_bs.vt
- banner-styled.golden
- banner.golden
- tuiosx.go
- tuiosx_test.go
- .gitignore
- api_test.go
- bench_test.go
- encode_test.go
- exitcode_test.go
- fuzz_test.go
- go.mod
- go.sum
- integration_test.go
- keys.go
- LICENSE
- mouse.go
- README.md
- screen.go
- snapshot.go
- state.go
- state_test.go
- teardown_test.go
- terminal.go
- vtdiff_test.go
- wait.go
# Use via CDN
jsDelivrjsDelivr serves any public GitHub repository as a CDN with zero setup. Pick a version and a file to get a ready-to-paste link and snippet.
Command Glossary
Commands referenced in this DOCs, explained below.
Line
View Details ▼
Line
Manage lines.
Accessed in configuration mode.
line vty 0 15
Configure lines from 0 to 15:
line
Read input:
go build
View Details ▼
go build
Compile Go sources.
go build {{path/to/main.go}}
Compile a 'package main' file (output will be the filename without extension):
go build -o {{path/to/binary}} {{path/to/source.go}}
Compile, specifying the output filename:
go build -o {{path/to/binary}} {{path/to/package}}
Compile a package:
go get
View Details ▼
go get
Add a dependency package, or download packages in legacy GOPATH mode.
Note: `./...` is a Go package pattern understood by Go tooling. It matches the current package and all packages recursively under the current directory.
go get {{example.com/pkg}}
Add a specified package to `go.mod` in module-mode or install the package in GOPATH-mode:
go get {{example.com/pkg}}@{{v1.2.3}}
Modify the package with a given version in module-aware mode:
go get {{example.com/pkg}}@{{none}}
Remove a specified package:
go install
View Details ▼
go install
Compile and install packages named by the import paths.
go install
Compile and install the current package:
go install {{path/to/package}}
Compile and install a specific local package:
go install {{golang.org/x/tools/gopls}}@{{latest}}
Install the latest version of a program, ignoring `go.mod` in the current directory:
go test
View Details ▼
go test
Test Go packages (files have to end with `_test.go`).
Note: `./...` is a Go package pattern understood by Go tooling. It matches the current package and all packages recursively under the current directory.
go test
Test the package found in the current directory:
go test -v
[v]erbosely test the package in the current directory:
go test -v ./...
Test the packages in the current directory and all subdirectories:
go vet
View Details ▼
go vet
Check Go source code and report suspicious constructs (e.g. lint your Go source files).
Go vet returns a non-zero exit code if problems are found; returns a zero exit code if no problems are found.
go vet
Check the Go package in the current directory:
go vet {{path/to/file_or_directory}}
Check the Go package in the specified path:
go tool vet help
List available checks that can be run with go vet:
kind
View Details ▼
kind
Run local Kubernetes clusters using Docker container "nodes".
Designed for testing Kubernetes itself, but may be used for local development or continuous integration.
kind create cluster --name {{cluster_name}}
Create a local Kubernetes cluster:
kind delete clusters {{cluster_name}}
Delete one or more clusters:
kind get {{clusters|nodes|kubeconfig}}
Get details about clusters, nodes, or the kubeconfig:
lazygit
View Details ▼
lazygit
A simple terminal UI for Git commands, providing an intuitive interface for managing repositories.
lazygit
Open Lazygit in the current repository:
lazygit {{[-p|--path]}} {{path/to/repository}}
Open Lazygit for a specific Git repository:
lazygit {{status|branch|log|stash|...}}
Start Lazygit with focus on a specific panel:
regex
View Details ▼
regex
Regular expressions (`regex`) are patterns used to match, search, and manipulate text.
Note: `regex` isn't a command, but syntax to be used with other commands.
See also: `egrep`, `glob`.
.
Match any single character:
^{{hello}}
Match the start of a line:
{{world}}$
Match the end of a line:
Screen
View Details ▼
Screen
Hold a session open on a remote server. Manage multiple windows with a single SSH connection.
See also: `tmux`, `zellij`, `herdr`.
screen
Start a new screen session:
screen -S {{session_name}}
Start a new named screen session:
screen -dmLS {{session_name}} {{command}}
Start a new daemon and log the output to `screenlog.x`:
timeout
View Details ▼
timeout
Run a command with a time limit.
timeout 3s sleep 10
Run `sleep 10` and terminate it after 3 seconds:
timeout {{[-s|--signal]}} {{INT|HUP|KILL|...}} {{5s}} {{sleep 10}}
Send a signal to the command after the time limit expires (`TERM` by default, `kill -l` to list all signals):
timeout {{[-v|--verbose]}} {{0.5s|1m|1h|1d|...}} {{command}}
Send verbose output to `stderr` showing signal sent upon timeout:
vim
View Details ▼
vim
Vim (Vi IMproved), a command-line text editor, provides several modes for different kinds of text manipulation.
Pressing `<i>` in normal mode enters insert mode. Pressing `<Esc>` goes back to normal mode, which enables the use of Vim commands.
See also: `vimdiff`, `vimtutor`, `nvim`, `gvim`.
vim {{path/to/file}}
Open a file:
vim +{{line_number}} {{path/to/file}}
Open a file at a specified line number:
<:>help<Enter>
View Vim's help manual:
expect
View Details ▼
expect
Script executor that interacts with other programs that require user input.
expect {{path/to/file}}
Execute an expect script from a file:
expect -c "{{commands}}"
Execute a specified expect script:
expect -i
Enter an [i]nteractive REPL (use `exit` or `<Ctrl d>` to exit):
setsid
View Details ▼
setsid
Run a program in a new session if the calling process is not a process group leader.
The created session is by default not controlled by the current terminal.
setsid {{program}}
Run a program in a new session:
setsid {{program}} > /dev/null 2>&1
Run a program in a new session discarding the resulting output and error:
setsid {{[-f|--fork]}} {{program}}
Run a program creating a new process:
snap
View Details ▼
snap
Manage the "snap" self-contained software packages.
Similar to what `apt` is for `.deb`.
snap find {{query}}
Search for a package:
snap install {{package}}
Install a package:
snap refresh {{package}}
Update a package:
# Project Badges
-
Go reference Visit
