Skip to content

Run Lua examples for navigating, moving and laying out tmux windows - #182

Merged
tony merged 1 commit into
masterfrom
window-showcase
Dec 6, 2026
Merged

tony merged 1 commit into
masterfrom
window-showcase

Conversation

@tony

@tony tony commented Dec 5, 2026 •

Copy link
Copy Markdown
Contributor

Summary

Run these Lua examples with tmux 3.3a or newer on PATH. They follow a session’s window link to a pane, move a window, and change a window’s layout. Build the checkout rock and install luv first. Example setup.

$ lua examples/api/navigate.lua
work / editor / pane 0
$ lua examples/api/move_window.lua
logs moved to ops:5
$ lua examples/api/set_layout.lua
panes stacked vertically

The example manifest records the output the installed package check expects.

Test plan

  • Run all three examples with TMUX_BIN unset on Lua 5.1.5 with tmux 3.3a and Lua 5.5.1 with tmux 3.8. Each printed its expected line and cleaned up its private server.
  • Run luajit scripts/support/run_tests.lua scripts/docs/tests/test_api_examples.lua.
  • Pass the docs, format, and type and editor checks.

Hosted checks.

Related to #84.

Selecting tmux

The window examples use tmux from PATH. Set TMUX_BIN to an absolute executable path to select a different build. Runtime PATH support.

why:
Readers need a complete program they can run to see how a tmux session
links to a window and its pane.

what:
- Follow the session’s window link in a snapshot.
- Run move-window and select-layout in separate examples and check the
  expected output of all three programs.
@tony
tony force-pushed the vote-counter-demo branch from c48d1e5 to d7f3165 Compare December 6, 2026 14:23
@tony
tony deployed to docs-preview December 6, 2026 14:29 — with GitHub Actions Active
@tony
tony changed the base branch from vote-counter-demo to master December 6, 2026 14:31
@tony
tony merged commit 5759f34 into master Dec 6, 2026
15 checks passed
@tony
tony deleted the window-showcase branch December 6, 2026 14:32

This branch was successfully deployed

1 active deployment
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant