Skip to content

Instantly share code, notes, and snippets.

@lakshmankumar12
Created June 25, 2015 00:01
Show Gist options
  • Save lakshmankumar12/298d17be96cb16969c85 to your computer and use it in GitHub Desktop.
Save lakshmankumar12/298d17be96cb16969c85 to your computer and use it in GitHub Desktop.
tmux fix to get pane-title as the new window-title, when we break out a pane
index d0a5a45..8445ba3 100644
--- a/cmd-break-pane.c
+++ b/cmd-break-pane.c
@@ -80,9 +80,9 @@ cmd_break_pane_exec(struct cmd *self, struct cmd_q *cmdq)
w = wp->window = window_create1(s->sx, s->sy);
TAILQ_INSERT_HEAD(&w->panes, wp, entry);
w->active = wp;
- name = default_window_name(w);
+ name = wp->base.title;
window_set_name(w, name);
- free(name);
+ options_set_number(&w->options, "automatic-rename", 0);
layout_init(w, wp);
base_idx = options_get_number(&s->options, "base-index");
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment