Skip to content

Commit 2ca8063

Browse files
committed
hooks.py(fix[set_hook]): Remove invalid prevent_overwrite parameter
why: tmux set-hook does not accept -o flag (only set-option does). Verified against ~/study/c/tmux/cmd-set-option.c:65 which shows set-hook accepts "agpRt:uw" only. what: - Remove prevent_overwrite parameter from set_hook() signature - Remove prevent_overwrite flag handling code
1 parent da38b70 commit 2ca8063

File tree

1 file changed

+0
-5
lines changed

1 file changed

+0
-5
lines changed

src/libtmux/hooks.py

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -113,7 +113,6 @@ def set_hook(
113113
value: int | str,
114114
unset: bool | None = None,
115115
run: bool | None = None,
116-
prevent_overwrite: bool | None = None,
117116
ignore_errors: bool | None = None,
118117
append: bool | None = None,
119118
g: bool | None = None,
@@ -157,10 +156,6 @@ def set_hook(
157156
assert isinstance(run, bool)
158157
flags.append("-R")
159158

160-
if prevent_overwrite is not None and prevent_overwrite:
161-
assert isinstance(prevent_overwrite, bool)
162-
flags.append("-o")
163-
164159
if ignore_errors is not None and ignore_errors:
165160
assert isinstance(ignore_errors, bool)
166161
flags.append("-q")

0 commit comments

Comments
 (0)