Skip to content
Permalink

Comparing changes

Choose two branches to see what’s changed or to start a new pull request. If you need to, you can also or learn more about diff comparisons.

Open a pull request

Create a new pull request by comparing changes across two branches. If you need to, you can also . Learn more about diff comparisons here.
base repository: tmux-python/libtmux
Failed to load repositories. Confirm that selected base ref is valid, then try again.
Loading
base: v0.51.0
Choose a base ref
...
head repository: tmux-python/libtmux
Failed to load repositories. Confirm that selected head ref is valid, then try again.
Loading
compare: v0.52.0
Choose a head ref
  • 8 commits
  • 8 files changed
  • 1 contributor

Commits on Dec 7, 2025

  1. py(deps[dev]) Bump dev packages

    tony committed Dec 7, 2025
    Configuration menu
    Copy the full SHA
    c6f78e6 View commit details
    Browse the repository at this point in the history
  2. Configuration menu
    Copy the full SHA
    bd13b1e View commit details
    Browse the repository at this point in the history
  3. Pane(feat[capture_pane]): Add 5 new flag parameters

    why: Expose more tmux capture-pane capabilities for advanced use cases
    like capturing colored output, handling wrapped lines, and controlling
    trailing space behavior.
    
    what:
    - Add escape_sequences parameter (-e flag) for ANSI escape sequences
    - Add escape_non_printable parameter (-C flag) for octal escapes
    - Add join_wrapped parameter (-J flag) for joining wrapped lines
    - Add preserve_trailing parameter (-N flag) for trailing spaces
    - Add trim_trailing parameter (-T flag) with tmux 3.4+ version check
    - Issue warning when trim_trailing used with tmux < 3.4
    tony committed Dec 7, 2025
    Configuration menu
    Copy the full SHA
    420830f View commit details
    Browse the repository at this point in the history
  4. tests(pane): Add exhaustive capture_pane() flag tests

    why: Ensure comprehensive coverage of all capture_pane() flag
    combinations with parametrized test cases.
    
    what:
    - Add CapturePaneCase NamedTuple for test case definitions
    - Add 16 parametrized test cases covering all flag variations
    - Add backward compatibility test for existing code
    - Add start/end parameters test with new flags
    - Add trim_trailing warning test for tmux version check
    - Use marker-based completion detection for reliability
    tony committed Dec 7, 2025
    Configuration menu
    Copy the full SHA
    601c322 View commit details
    Browse the repository at this point in the history
  5. docs(CHANGES): Document capture_pane() enhancements

    why: Document the new capture_pane() parameters for the changelog.
    
    what:
    - Add section for Pane.capture_pane() enhanced
    - Document all 5 new parameters with flag mappings
    - Add code examples for colored output and joined lines
    - Note trim_trailing requires tmux 3.4+
    tony committed Dec 7, 2025
    Configuration menu
    Copy the full SHA
    b6c6f33 View commit details
    Browse the repository at this point in the history
  6. docs(pane_interaction): Add capture_pane() flag examples

    why: Provide practical examples for the new capture_pane() parameters
    in the pane interaction topic documentation.
    
    what:
    - Add section for capturing ANSI escape sequences
    - Add section for joining wrapped lines
    - Add section for preserving trailing spaces
    - Add capture flags summary table
    - Add note about trim_trailing tmux 3.4+ requirement
    tony committed Dec 7, 2025
    Configuration menu
    Copy the full SHA
    279b6d4 View commit details
    Browse the repository at this point in the history
  7. feat(Pane[capture_pane]) Support new capture-pane flags (#614)

    #### Pane.capture_pane() enhanced (#614)
    
    The {meth}`~libtmux.pane.Pane.capture_pane` method now supports 5 new parameters
    that expose additional tmux `capture-pane` flags:
    
    | Parameter | tmux Flag | Description |
    |-----------|-----------|-------------|
    | `escape_sequences` | `-e` | Include ANSI escape sequences (colors, attributes) |
    | `escape_non_printable` | `-C` | Escape non-printable chars as octal `\xxx` |
    | `join_wrapped` | `-J` | Join wrapped lines back together |
    | `preserve_trailing` | `-N` | Preserve trailing spaces at line ends |
    | `trim_trailing` | `-T` | Trim trailing empty positions (tmux 3.4+) |
    
    **Capturing colored output:**
    
    ```python
    # Capture with ANSI escape sequences preserved
    pane.send_keys('printf "\\033[31mRED\\033[0m"', enter=True)
    output = pane.capture_pane(escape_sequences=True)
    # Output contains: '\x1b[31mRED\x1b[0m'
    ```
    
    **Joining wrapped lines:**
    
    ```python
    # Long lines that wrap are joined back together
    output = pane.capture_pane(join_wrapped=True)
    ```
    
    **Version compatibility:**
    
    The `trim_trailing` parameter requires tmux 3.4+. If used with an older version,
    a warning is issued and the flag is ignored. All other parameters work with
    libtmux's minimum supported version (tmux 3.2a).
    tony authored Dec 7, 2025
    Configuration menu
    Copy the full SHA
    7fca580 View commit details
    Browse the repository at this point in the history
  8. Configuration menu
    Copy the full SHA
    4df1128 View commit details
    Browse the repository at this point in the history
Loading