### Configure Wez Pain Control in WezTerm Source: https://context7.com/sei40kr/wez-pain-control/llms.txt Registers the plugin with the WezTerm configuration. Includes examples for default initialization and custom pane resize settings. ```lua local wezterm = require("wezterm") local config = {} if wezterm.config_builder then config = wezterm.config_builder() end config.leader = { key = "b", mods = "CTRL" } require("wez-pain-control.plugin").apply_to_config(config, {}) ``` ```lua require("wez-pain-control.plugin").apply_to_config(config, { pane_resize = 10, }) ``` -------------------------------- ### Install wez-pain-control using Git Source: https://github.com/sei40kr/wez-pain-control/blob/main/README.md This command clones the wez-pain-control repository into the WezTerm configuration directory. Ensure that `$XDG_CONFIG_HOME` is set correctly in your environment. ```shell git clone https://github.com/sei40kr/wez-pain-control.git $XDG_CONFIG_HOME/wezterm ``` -------------------------------- ### Nix Integration for WezTerm Plugin (Nix) Source: https://context7.com/sei40kr/wez-pain-control/llms.txt Demonstrates how to integrate the Wez Pain Control plugin into a Nix development environment using flakes. This ensures reproducible builds and provides a pre-configured WezTerm instance with the plugin loaded and a specific leader key set. ```nix # Add to your flake inputs { inputs = { wez-pain-control.url = "github:sei40kr/wez-pain-control"; }; } # Use the development shell with pre-configured WezTerm # $ nix develop # $ wezterm # Launches with plugin pre-loaded and Ctrl+b as leader # The dev shell automatically configures: # - Package path to include the plugin # - Leader key set to Ctrl+b # - All pane control bindings active ``` -------------------------------- ### Pane Management Key Bindings Source: https://context7.com/sei40kr/wez-pain-control/llms.txt Reference for key bindings used for navigation, resizing, and splitting panes. Includes logic for repeatable resize modes and split directions. ```lua -- Resize mode example { key = "h", mods = "SHIFT", action = AdjustPaneSize({ "Left", 5 }) }, { key = "Escape", action = PopKeyTable }, -- Split example { key = "|", mods = "LEADER|SHIFT", action = SplitHorizontal({ domain = "CurrentPaneDomain" }) }, { key = "-", mods = "LEADER", action = SplitVertical({ domain = "CurrentPaneDomain" }) } ``` -------------------------------- ### Move Tabs Left/Right with Leader Key (Lua) Source: https://context7.com/sei40kr/wez-pain-control/llms.txt Configures key bindings to move the current tab one position left or right within the tab bar using the leader prefix combined with angle bracket keys. This functionality requires the leader key to be defined in the WezTerm configuration. ```lua -- Key bindings registered for tab management: -- leader+< (less than): Move current tab one position to the left -- leader+> (greater than): Move current tab one position to the right -- Example: With leader set to Ctrl+b -- Press Ctrl+b, then Shift+, (<) to move tab left -- Press Ctrl+b, then Shift+. (>) to move tab right -- { key = "<", mods = "LEADER|SHIFT", action = MoveTabRelative(-1) } -- { key = ">", mods = "LEADER|SHIFT", action = MoveTabRelative(1) } ``` -------------------------------- ### Configure WezTerm to use wez-pain-control plugin Source: https://github.com/sei40kr/wez-pain-control/blob/main/README.md This Lua code snippet integrates the wez-pain-control plugin into your WezTerm configuration. It requires the 'wezterm' module and applies the plugin's functionality to the WezTerm configuration object. ```lua local wezterm = require("wezterm") local config = {} if wezterm.config_builder then config = wezterm.config_builder() end -- Add these lines: require("wez-pain-control.plugin").apply_to_config(config, {}) return config ``` -------------------------------- ### Customize wez-pain-control pane resize option Source: https://github.com/sei40kr/wez-pain-control/blob/main/README.md This Lua snippet demonstrates how to set custom options for the wez-pain-control plugin, specifically configuring the `pane_resize` value. The `pane_resize` option controls the number of cells panes are resized by. ```lua require("wez-pain-control.plugin").apply_to_config(config, { pane_resize = 5, }) ``` === COMPLETE CONTENT === This response contains all available snippets from this library. No additional content exists. Do not make further requests.