commit 0d711d067c2cb3968bf4a4c218752de646cdaf993addab881113cb4096f638fd Author: Adrian Schröter Date: Sat May 4 01:25:35 2024 +0200 Sync from SUSE:SLFO:Main tmux revision 2974142f383e8cf2a64558c3ac51abbe diff --git a/.gitattributes b/.gitattributes new file mode 100644 index 0000000..9b03811 --- /dev/null +++ b/.gitattributes @@ -0,0 +1,23 @@ +## Default LFS +*.7z filter=lfs diff=lfs merge=lfs -text +*.bsp filter=lfs diff=lfs merge=lfs -text +*.bz2 filter=lfs diff=lfs merge=lfs -text +*.gem filter=lfs diff=lfs merge=lfs -text +*.gz filter=lfs diff=lfs merge=lfs -text +*.jar filter=lfs diff=lfs merge=lfs -text +*.lz filter=lfs diff=lfs merge=lfs -text +*.lzma filter=lfs diff=lfs merge=lfs -text +*.obscpio filter=lfs diff=lfs merge=lfs -text +*.oxt filter=lfs diff=lfs merge=lfs -text +*.pdf filter=lfs diff=lfs merge=lfs -text +*.png filter=lfs diff=lfs merge=lfs -text +*.rpm filter=lfs diff=lfs merge=lfs -text +*.tbz filter=lfs diff=lfs merge=lfs -text +*.tbz2 filter=lfs diff=lfs merge=lfs -text +*.tgz filter=lfs diff=lfs merge=lfs -text +*.ttf filter=lfs diff=lfs merge=lfs -text +*.txz filter=lfs diff=lfs merge=lfs -text +*.whl filter=lfs diff=lfs merge=lfs -text +*.xz filter=lfs diff=lfs merge=lfs -text +*.zip filter=lfs diff=lfs merge=lfs -text +*.zst filter=lfs diff=lfs merge=lfs -text diff --git a/bash_completion_tmux.sh b/bash_completion_tmux.sh new file mode 100644 index 0000000..8be1f91 --- /dev/null +++ b/bash_completion_tmux.sh @@ -0,0 +1,102 @@ +# START tmux completion +# This file is in the public domain +# See: http://www.debian-administration.org/articles/317 for how to write more. +# Usage: Put "source bash_completion_tmux.sh" into your .bashrc +_tmux() +{ + local cur prev opts + COMPREPLY=() + cur="${COMP_WORDS[COMP_CWORD]}" + prev="${COMP_WORDS[COMP_CWORD-1]}" + + opts=" \ + attach-session \ + bind-key \ + break-pane \ + capture-pane \ + choose-client \ + choose-session \ + choose-window \ + clear-history \ + clock-mode \ + command-prompt \ + confirm-before \ + copy-buffer \ + copy-mode \ + delete-buffer \ + detach-client \ + display-message \ + display-panes \ + down-pane \ + find-window \ + has-session \ + if-shell \ + join-pane \ + kill-pane \ + kill-server \ + kill-session \ + kill-window \ + last-window \ + link-window \ + list-buffers \ + list-clients \ + list-commands \ + list-keys \ + list-panes \ + list-sessions \ + list-windows \ + load-buffer \ + lock-client \ + lock-server \ + lock-session \ + move-window \ + new-session \ + new-window \ + next-layout \ + next-window \ + paste-buffer \ + pipe-pane \ + previous-layout \ + previous-window \ + refresh-client \ + rename-session \ + rename-window \ + resize-pane \ + respawn-window \ + rotate-window \ + run-shell \ + save-buffer \ + select-layout \ + select-pane \ + select-prompt \ + select-window \ + send-keys \ + send-prefix \ + server-info \ + set-buffer \ + set-environment \ + set-option \ + set-window-option \ + show-buffer \ + show-environment \ + show-messages \ + show-options \ + show-window-options \ + source-file \ + split-window \ + start-server \ + suspend-client \ + swap-pane \ + swap-window \ + switch-client \ + unbind-key \ + unlink-window \ + up-pane" + + COMPREPLY=($(compgen -W "${opts}" -- ${cur})) + return 0 + +} +complete -F _tmux tmux + +# END tmux completion diff --git a/ncurses.patch b/ncurses.patch new file mode 100644 index 0000000..7dfa15b --- /dev/null +++ b/ncurses.patch @@ -0,0 +1,816 @@ +diff --git a/compat.h b/compat.h +index cabdf3ad..7b543128 100644 +--- a/compat.h ++++ b/compat.h +@@ -435,6 +435,11 @@ int utf8proc_mbtowc(wchar_t *, const char *, size_t); + int utf8proc_wctomb(char *, wchar_t); + #endif + ++/* tparm.c */ ++#ifndef HAVE_TIPARM ++char *compat_tiparm(const char *, ...); ++#endif ++ + #ifdef NEED_FUZZING + /* tmux.c */ + #define main __weak main +diff --git a/compat/tiparm.c b/compat/tiparm.c +new file mode 100644 +index 00000000..01d0adf0 +--- /dev/null ++++ b/compat/tiparm.c +@@ -0,0 +1,655 @@ ++/* $NetBSD: tparm.c,v 1.19 2021/08/27 18:40:28 rillig Exp $ */ ++ ++/* ++ * Copyright (c) 2009, 2011, 2013 The NetBSD Foundation, Inc. ++ * ++ * This code is derived from software contributed to The NetBSD Foundation ++ * by Roy Marples. ++ * ++ * Redistribution and use in source and binary forms, with or without ++ * modification, are permitted provided that the following conditions ++ * are met: ++ * 1. Redistributions of source code must retain the above copyright ++ * notice, this list of conditions and the following disclaimer. ++ * 2. Redistributions in binary form must reproduce the above copyright ++ * notice, this list of conditions and the following disclaimer in the ++ * documentation and/or other materials provided with the distribution. ++ * ++ * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR ++ * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES ++ * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. ++ * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, ++ * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT ++ * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, ++ * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY ++ * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT ++ * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF ++ * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. ++ */ ++ ++#include ++#if 0 ++__RCSID("$NetBSD: tparm.c,v 1.19 2021/08/27 18:40:28 rillig Exp $"); ++#endif ++#include ++ ++#include ++#include ++#include ++#include ++#include ++#include ++#include ++#if 0 ++#include ++#include ++#endif ++ ++#define TPARM_MAX 9 /* not likely to change */ ++ ++typedef struct { ++ /* Output buffer for tparm */ ++ char *_buf; ++ size_t _buflen; ++ size_t _bufpos; ++ /* A-Z static variables for tparm */ ++ long _snums[26]; ++} TERMINAL; ++ ++#define _DIAGASSERT(x) ++ ++#define LONG_STR_MAX ((CHAR_BIT * sizeof(long)) / 3) ++#define BUFINC 128 /* Size to increment the terminal buffer by */ ++ ++#define VA_LONG_LONG 1 ++#define VA_CHAR_INT 2 ++//#define VA_CHAR_LONG 3 /* No need for this yet */ ++ ++static TERMINAL *dumbterm; /* For non thread safe functions */ ++ ++typedef struct { ++ long nums[20]; ++ char *strings[20]; ++ size_t offset; ++} TPSTACK; ++ ++typedef struct { ++ long num; ++ char *string; ++} TPVAR; ++ ++static int ++push(long num, char *string, TPSTACK *stack) ++{ ++ if (stack->offset >= sizeof(stack->nums)) { ++ errno = E2BIG; ++ return -1; ++ } ++ stack->nums[stack->offset] = num; ++ stack->strings[stack->offset] = string; ++ stack->offset++; ++ return 0; ++} ++ ++static int ++pop(long *num, char **string, TPSTACK *stack) ++{ ++ if (stack->offset == 0) { ++ if (num) ++ *num = 0; ++ if (string) ++ *string = NULL; ++ errno = E2BIG; ++ return -1; ++ } ++ stack->offset--; ++ if (num) ++ *num = stack->nums[stack->offset]; ++ if (string) ++ *string = stack->strings[stack->offset]; ++ return 0; ++} ++ ++static char * ++checkbuf(TERMINAL *term, size_t len) ++{ ++ char *buf; ++ ++ if (term->_bufpos + len >= term->_buflen) { ++ len = term->_buflen + MAX(len, BUFINC); ++ buf = realloc(term->_buf, len); ++ if (buf == NULL) ++ return NULL; ++ term->_buf = buf; ++ term->_buflen = len; ++ } ++ return term->_buf; ++} ++ ++static size_t ++ochar(TERMINAL *term, int c) ++{ ++ if (c == 0) ++ c = 0200; ++ /* Check we have space and a terminator */ ++ if (checkbuf(term, 2) == NULL) ++ return 0; ++ term->_buf[term->_bufpos++] = (char)c; ++ return 1; ++} ++ ++static size_t ++onum(TERMINAL *term, const char *fmt, int num, size_t len) ++{ ++ int l; ++ size_t r; ++ ++ if (len < LONG_STR_MAX) ++ len = LONG_STR_MAX; ++ if (checkbuf(term, len + 2) == NULL) ++ return 0; ++ l = snprintf(term->_buf + term->_bufpos, len + 2, fmt, num); ++ if (l == -1) ++ return 0; ++ r = (size_t)l; ++ term->_bufpos += r; ++ return r; ++} ++ ++/* ++ Make a pass through the string so we can work out ++ which parameters are ints and which are char *. ++ Basically we only use char * if %p[1-9] is followed by %l or %s. ++*/ ++static int ++_ti_parm_analyse(const char *str, int *piss, int piss_len) ++{ ++ int nparm, lpop; ++ char c; ++ ++ nparm = 0; ++ lpop = -1; ++ while ((c = *str++) != '\0') { ++ if (c != '%') ++ continue; ++ c = *str++; ++ switch (c) { ++ case 'l': ++ case 's': ++ if (lpop > 0) { ++ if (lpop <= piss_len) ++ piss[lpop - 1] = 1; ++ else if (piss) ++ errno = E2BIG; ++ } ++ break; ++ case 'p': ++ c = *str++; ++ if (c < '1' || c > '9') { ++ errno = EINVAL; ++ continue; ++ } else { ++ lpop = c - '0'; ++ if (lpop > nparm) ++ nparm = lpop; ++ } ++ break; ++ default: ++ lpop = -1; ++ } ++ } ++ ++ return nparm; ++} ++ ++static char * ++_ti_tiparm(TERMINAL *term, const char *str, int va_type, va_list parms) ++{ ++ char c, fmt[64], *fp, *ostr; ++ long val, val2; ++ long dnums[26]; /* dynamic variables a-z, not preserved */ ++ size_t l, max, width, precision, olen; ++ TPSTACK stack; ++ TPVAR params[TPARM_MAX]; ++ unsigned int done, dot, minus; ++ int piss[TPARM_MAX]; /* Parameter IS String - piss ;) */ ++ ++ if (str == NULL) ++ return NULL; ++ ++ /* ++ If not passed a terminal, malloc a dummy one. ++ This means we can preserve buffers and variables per terminal and ++ still work with non thread safe functions (which sadly are still the ++ norm and standard). ++ */ ++ if (term == NULL) { ++ if (dumbterm == NULL) { ++ dumbterm = malloc(sizeof(*dumbterm)); ++ if (dumbterm == NULL) ++ return NULL; ++ dumbterm->_buflen = 0; ++ } ++ term = dumbterm; ++ } ++ ++ term->_bufpos = 0; ++ /* Ensure we have an initial buffer */ ++ if (term->_buflen == 0) { ++ term->_buf = malloc(BUFINC); ++ if (term->_buf == NULL) ++ return NULL; ++ term->_buflen = BUFINC; ++ } ++ ++ memset(&piss, 0, sizeof(piss)); ++ max = (size_t)_ti_parm_analyse(str, piss, TPARM_MAX); ++ ++ /* Put our parameters into variables */ ++ memset(¶ms, 0, sizeof(params)); ++ for (l = 0; l < max; l++) { ++ if (piss[l]) { ++ if (va_type == VA_LONG_LONG) { ++ /* This only works if char * fits into a long ++ * on this platform. */ ++ if (sizeof(char *) <= sizeof(long)) ++ params[l].string = ++ (char *)va_arg(parms, long); ++ else { ++ errno = ENOTSUP; ++ return NULL; ++ } ++ } else ++ params[l].string = va_arg(parms, char *); ++ } else { ++ if (va_type == VA_CHAR_INT) ++ params[l].num = (long)va_arg(parms, int); ++ else ++ params[l].num = va_arg(parms, long); ++ } ++ } ++ ++ memset(&stack, 0, sizeof(stack)); ++ while ((c = *str++) != '\0') { ++ if (c != '%' || (c = *str++) == '%') { ++ if (c == '\0') ++ break; ++ if (ochar(term, c) == 0) ++ return NULL; ++ continue; ++ } ++ ++ /* Handle formatting. */ ++ fp = fmt; ++ *fp++ = '%'; ++ done = dot = minus = 0; ++ width = precision = 0; ++ val = 0; ++ while (done == 0 && (size_t)(fp - fmt) < sizeof(fmt)) { ++ switch (c) { ++ case 'c': ++ case 's': ++ *fp++ = c; ++ done = 1; ++ break; ++ case 'd': ++ case 'o': ++ case 'x': ++ case 'X': ++ *fp++ = 'l'; ++ *fp++ = c; ++ done = 1; ++ break; ++ case '#': ++ case ' ': ++ *fp++ = c; ++ break; ++ case '.': ++ *fp++ = c; ++ if (dot == 0) { ++ dot = 1; ++ width = (size_t)val; ++ } else ++ done = 2; ++ val = 0; ++ break; ++ case ':': ++ minus = 1; ++ break; ++ case '-': ++ if (minus) ++ *fp++ = c; ++ else ++ done = 1; ++ break; ++ default: ++ if (isdigit((unsigned char)c)) { ++ val = (val * 10) + (c - '0'); ++ if (val > 10000) ++ done = 2; ++ else ++ *fp++ = c; ++ } else ++ done = 1; ++ } ++ if (done == 0) ++ c = *str++; ++ } ++ if (done == 2) { ++ /* Found an error in the format */ ++ fp = fmt + 1; ++ *fp = *str; ++ olen = 0; ++ } else { ++ if (dot == 0) ++ width = (size_t)val; ++ else ++ precision = (size_t)val; ++ olen = MAX(width, precision); ++ } ++ *fp++ = '\0'; ++ ++ /* Handle commands */ ++ switch (c) { ++ case 'c': ++ pop(&val, NULL, &stack); ++ if (ochar(term, (unsigned char)val) == 0) ++ return NULL; ++ break; ++ case 's': ++ pop(NULL, &ostr, &stack); ++ if (ostr != NULL) { ++ int r; ++ ++ l = strlen(ostr); ++ if (l < (size_t)olen) ++ l = olen; ++ if (checkbuf(term, (size_t)(l + 1)) == NULL) ++ return NULL; ++ r = snprintf(term->_buf + term->_bufpos, l + 1, ++ fmt, ostr); ++ if (r != -1) ++ term->_bufpos += (size_t)r; ++ } ++ break; ++ case 'l': ++ pop(NULL, &ostr, &stack); ++ if (ostr == NULL) ++ l = 0; ++ else ++ l = strlen(ostr); ++#ifdef NCURSES_COMPAT_57 ++ if (onum(term, "%ld", (long)l, 0) == 0) ++ return NULL; ++#else ++ push((long)l, NULL, &stack); ++#endif ++ break; ++ case 'd': ++ case 'o': ++ case 'x': ++ case 'X': ++ pop(&val, NULL, &stack); ++ if (onum(term, fmt, (int)val, olen) == 0) ++ return NULL; ++ break; ++ case 'p': ++ if (*str < '1' || *str > '9') ++ break; ++ l = (size_t)(*str++ - '1'); ++ if (push(params[l].num, params[l].string, &stack)) ++ return NULL; ++ break; ++ case 'P': ++ pop(&val, NULL, &stack); ++ if (*str >= 'a' && *str <= 'z') ++ dnums[*str - 'a'] = val; ++ else if (*str >= 'A' && *str <= 'Z') ++ term->_snums[*str - 'A'] = val; ++ break; ++ case 'g': ++ if (*str >= 'a' && *str <= 'z') { ++ if (push(dnums[*str - 'a'], NULL, &stack)) ++ return NULL; ++ } else if (*str >= 'A' && *str <= 'Z') { ++ if (push(term->_snums[*str - 'A'], ++ NULL, &stack)) ++ return NULL; ++ } ++ break; ++ case 'i': ++ if (piss[0] == 0) ++ params[0].num++; ++ if (piss[1] == 0) ++ params[1].num++; ++ break; ++ case '\'': ++ if (push((long)(unsigned char)*str++, NULL, &stack)) ++ return NULL; ++ while (*str != '\0' && *str != '\'') ++ str++; ++ if (*str == '\'') ++ str++; ++ break; ++ case '{': ++ val = 0; ++ for (; isdigit((unsigned char)*str); str++) ++ val = (val * 10) + (*str - '0'); ++ if (push(val, NULL, &stack)) ++ return NULL; ++ while (*str != '\0' && *str != '}') ++ str++; ++ if (*str == '}') ++ str++; ++ break; ++ case '+': ++ case '-': ++ case '*': ++ case '/': ++ case 'm': ++ case 'A': ++ case 'O': ++ case '&': ++ case '|': ++ case '^': ++ case '=': ++ case '<': ++ case '>': ++ pop(&val, NULL, &stack); ++ pop(&val2, NULL, &stack); ++ switch (c) { ++ case '+': ++ val = val + val2; ++ break; ++ case '-': ++ val = val2 - val; ++ break; ++ case '*': ++ val = val * val2; ++ break; ++ case '/': ++ val = val ? val2 / val : 0; ++ break; ++ case 'm': ++ val = val ? val2 % val : 0; ++ break; ++ case 'A': ++ val = val && val2; ++ break; ++ case 'O': ++ val = val || val2; ++ break; ++ case '&': ++ val = val & val2; ++ break; ++ case '|': ++ val = val | val2; ++ break; ++ case '^': ++ val = val ^ val2; ++ break; ++ case '=': ++ val = val == val2; ++ break; ++ case '<': ++ val = val2 < val; ++ break; ++ case '>': ++ val = val2 > val; ++ break; ++ } ++ if (push(val, NULL, &stack)) ++ return NULL; ++ break; ++ case '!': ++ case '~': ++ pop(&val, NULL, &stack); ++ switch (c) { ++ case '!': ++ val = !val; ++ break; ++ case '~': ++ val = ~val; ++ break; ++ } ++ if (push(val, NULL, &stack)) ++ return NULL; ++ break; ++ case '?': /* if */ ++ break; ++ case 't': /* then */ ++ pop(&val, NULL, &stack); ++ if (val == 0) { ++ l = 0; ++ for (; *str != '\0'; str++) { ++ if (*str != '%') ++ continue; ++ str++; ++ if (*str == '?') ++ l++; ++ else if (*str == ';') { ++ if (l > 0) ++ l--; ++ else { ++ str++; ++ break; ++ } ++ } else if (*str == 'e' && l == 0) { ++ str++; ++ break; ++ } ++ } ++ } ++ break; ++ case 'e': /* else */ ++ l = 0; ++ for (; *str != '\0'; str++) { ++ if (*str != '%') ++ continue; ++ str++; ++ if (*str == '?') ++ l++; ++ else if (*str == ';') { ++ if (l > 0) ++ l--; ++ else { ++ str++; ++ break; ++ } ++ } ++ } ++ break; ++ case ';': /* fi */ ++ break; ++ } ++ } ++ term->_buf[term->_bufpos] = '\0'; ++ return term->_buf; ++} ++ ++#if 0 ++char * ++ti_tiparm(TERMINAL *term, const char *str, ...) ++{ ++ va_list va; ++ char *ret; ++ ++ _DIAGASSERT(term != NULL); ++ _DIAGASSERT(str != NULL); ++ ++ va_start(va, str); ++ ret = _ti_tiparm(term, str, VA_CHAR_INT, va); ++ va_end(va); ++ return ret; ++} ++#endif ++ ++char * ++compat_tiparm(const char *str, ...) ++{ ++ va_list va; ++ char *ret; ++ ++ _DIAGASSERT(str != NULL); ++ ++ va_start(va, str); ++ ret = _ti_tiparm(NULL, str, VA_CHAR_INT, va); ++ va_end(va); ++ return ret; ++} ++ ++#if 0 ++#ifdef VA_CHAR_LONG ++char * ++ti_tlparm(TERMINAL *term, const char *str, ...) ++{ ++ va_list va; ++ char *ret; ++ ++ _DIAGASSERT(term != NULL); ++ _DIAGASSERT(str != NULL); ++ ++ va_start(va, str); ++ ret = _ti_tiparm(term, str, VA_CHAR_LONG, va); ++ va_end(va); ++ return ret; ++} ++ ++char * ++tlparm(const char *str, ...) ++{ ++ va_list va; ++ char *ret; ++ ++ _DIAGASSERT(str != NULL); ++ ++ va_start(va, str); ++ ret = _ti_tiparm(NULL, str, VA_CHAR_LONG, va); ++ va_end(va); ++ return ret; ++} ++#endif ++ ++static char * ++_tparm(const char *str, ...) ++{ ++ va_list va; ++ char *ret; ++ ++ _DIAGASSERT(str != NULL); ++ ++ va_start(va, str); ++ ret = _ti_tiparm(NULL, str, VA_LONG_LONG, va); ++ va_end(va); ++ return ret; ++} ++ ++char * ++tparm(const char *str, ++ long p1, long p2, long p3, long p4, long p5, ++ long p6, long p7, long p8, long p9) ++{ ++ ++ return _tparm(str, p1, p2, p3, p4, p5, p6, p7, p8, p9); ++} ++#endif +diff --git a/configure.ac b/configure.ac +index 4b9d75b3..ccbedfee 100644 +--- a/configure.ac ++++ b/configure.ac +@@ -351,6 +351,37 @@ else + fi + fi + ++# Replace tparm on newer ncurses where it has string requirements that are ++# too strict for tmux (requires capabilities to exist). ++AC_MSG_CHECKING(for ncurses with suitable tiparm) ++AC_RUN_IFELSE([AC_LANG_SOURCE( ++ [ ++ #include ++ #if defined(HAVE_CURSES_H) ++ #include ++ #elif defined(HAVE_NCURSES_H) ++ #include ++ #endif ++ int main(void) { ++ #if defined(NCURSES_VERSION_MAJOR) && \ ++ (NCURSES_VERSION_MAJOR > 6 || \ ++ (NCURSES_VERSION_MAJOR == 6 && NCURSES_VERSION_MINOR > 3)) ++ exit(0); ++ #else ++ exit(1); ++ #endif ++ } ++ ])], ++ [ ++ AC_MSG_RESULT(no) ++ AC_LIBOBJ(tiparm) ++ ], ++ [ ++ AC_MSG_RESULT(yes) ++ AC_REPLACE_FUNCS(tiparm) ++ ] ++) ++ + # Look for utempter. + AC_ARG_ENABLE( + utempter, +@@ -438,7 +469,7 @@ fi + + # Check for b64_ntop. If we have b64_ntop, we assume b64_pton as well. + AC_MSG_CHECKING(for b64_ntop) +- AC_LINK_IFELSE([AC_LANG_PROGRAM( ++AC_LINK_IFELSE([AC_LANG_PROGRAM( + [ + #include + #include +diff --git a/tty-term.c b/tty-term.c +index 4e9b7799..6fad619f 100644 +--- a/tty-term.c ++++ b/tty-term.c +@@ -768,33 +768,78 @@ tty_term_string(struct tty_term *term, enum tty_code_code code) + const char * + tty_term_string1(struct tty_term *term, enum tty_code_code code, int a) + { +- return (tparm((char *) tty_term_string(term, code), a, 0, 0, 0, 0, 0, 0, 0, 0)); ++ const char *s; ++ ++#ifndef HAVE_TIPARM ++ s = compat_tiparm(tty_term_string(term, code), a); ++#else ++ s = tiparm(tty_term_string(term, code), a); ++#endif ++ if (s == NULL) ++ fatalx("could not expand %s", tty_term_codes[code].name); ++ return s; + } + + const char * + tty_term_string2(struct tty_term *term, enum tty_code_code code, int a, int b) + { +- return (tparm((char *) tty_term_string(term, code), a, b, 0, 0, 0, 0, 0, 0, 0)); ++ const char *s; ++ ++#ifndef HAVE_TIPARM ++ s = compat_tiparm(tty_term_string(term, code), a, b); ++#else ++ s = tiparm(tty_term_string(term, code), a, b); ++#endif ++ if (s == NULL) ++ fatalx("could not expand %s", tty_term_codes[code].name); ++ return s; + } + + const char * + tty_term_string3(struct tty_term *term, enum tty_code_code code, int a, int b, + int c) + { +- return (tparm((char *) tty_term_string(term, code), a, b, c, 0, 0, 0, 0, 0, 0)); ++ const char *s; ++ ++#ifndef HAVE_TIPARM ++ s = compat_tiparm(tty_term_string(term, code), a, b, c); ++#else ++ s = tiparm(tty_term_string(term, code), a, b, c); ++#endif ++ if (s == NULL) ++ fatalx("could not expand %s", tty_term_codes[code].name); ++ return s; + } + + const char * + tty_term_ptr1(struct tty_term *term, enum tty_code_code code, const void *a) + { +- return (tparm((char *) tty_term_string(term, code), (long)a, 0, 0, 0, 0, 0, 0, 0, 0)); ++ const char *s; ++ ++#ifndef HAVE_TIPARM ++ s = compat_tiparm(tty_term_string(term, code), a); ++#else ++ s = tiparm(tty_term_string(term, code), a); ++#endif ++ if (s == NULL) ++ fatalx("could not expand %s", tty_term_codes[code].name); ++ return s; + } + + const char * + tty_term_ptr2(struct tty_term *term, enum tty_code_code code, const void *a, + const void *b) + { +- return (tparm((char *) tty_term_string(term, code), (long)a, (long)b, 0, 0, 0, 0, 0, 0, 0)); ++ const char *s; ++ ++#ifndef HAVE_TIPARM ++ s = compat_tiparm(tty_term_string(term, code), a, b); ++#else ++ s = tiparm(tty_term_string(term, code), a, b); ++#endif ++ if (s == NULL) ++ fatalx("could not expand %s", tty_term_codes[code].name); ++ return s; + } + + int diff --git a/tmux-3.3a.tar.gz b/tmux-3.3a.tar.gz new file mode 100644 index 0000000..ae31278 --- /dev/null +++ b/tmux-3.3a.tar.gz @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:e4fd347843bd0772c4f48d6dde625b0b109b7a380ff15db21e97c11a4dcdf93f +size 677448 diff --git a/tmux-CVE-2022-47016.patch b/tmux-CVE-2022-47016.patch new file mode 100644 index 0000000..fe8e356 --- /dev/null +++ b/tmux-CVE-2022-47016.patch @@ -0,0 +1,58 @@ +Index: tmux-3.3a/control.c +=================================================================== +--- tmux-3.3a.orig/control.c ++++ tmux-3.3a/control.c +@@ -775,6 +775,9 @@ control_start(struct client *c) + + cs->read_event = bufferevent_new(c->fd, control_read_callback, + control_write_callback, control_error_callback, c); ++ if (cs->read_event == NULL) ++ fatalx("out of memory"); ++ + bufferevent_enable(cs->read_event, EV_READ); + + if (c->flags & CLIENT_CONTROLCONTROL) +@@ -782,6 +785,8 @@ control_start(struct client *c) + else { + cs->write_event = bufferevent_new(c->out_fd, NULL, + control_write_callback, control_error_callback, c); ++ if (cs->write_event == NULL) ++ fatalx("out of memory"); + } + bufferevent_setwatermark(cs->write_event, EV_WRITE, CONTROL_BUFFER_LOW, + 0); +Index: tmux-3.3a/file.c +=================================================================== +--- tmux-3.3a.orig/file.c ++++ tmux-3.3a/file.c +@@ -585,6 +585,8 @@ file_write_open(struct client_files *fil + + cf->event = bufferevent_new(cf->fd, NULL, file_write_callback, + file_write_error_callback, cf); ++ if (cf->event == NULL) ++ fatalx("out of memory"); + bufferevent_enable(cf->event, EV_WRITE); + goto reply; + +@@ -744,6 +746,8 @@ file_read_open(struct client_files *file + + cf->event = bufferevent_new(cf->fd, file_read_callback, NULL, + file_read_error_callback, cf); ++ if (cf->event == NULL) ++ fatalx("out of memory"); + bufferevent_enable(cf->event, EV_READ); + return; + +Index: tmux-3.3a/window.c +=================================================================== +--- tmux-3.3a.orig/window.c ++++ tmux-3.3a/window.c +@@ -1042,6 +1042,8 @@ window_pane_set_event(struct window_pane + + wp->event = bufferevent_new(wp->fd, window_pane_read_callback, + NULL, window_pane_error_callback, wp); ++ if (wp->event == NULL) ++ fatalx("out of memory"); + wp->ictx = input_init(wp, wp->event, &wp->palette); + + bufferevent_enable(wp->event, EV_READ|EV_WRITE); diff --git a/tmux-socket-path.patch b/tmux-socket-path.patch new file mode 100644 index 0000000..2dd47af --- /dev/null +++ b/tmux-socket-path.patch @@ -0,0 +1,40 @@ +--- tmux-3.3/tmux.c 2022-05-14 21:04:35.000000000 +0200 ++++ tmux-3.3/tmux.c 2022-06-04 09:08:04.005234096 +0200 +@@ -198,16 +198,16 @@ + + expand_paths(TMUX_SOCK, &paths, &n, 1); + if (n == 0) { +- xasprintf(cause, "no suitable socket path"); +- return (NULL); ++ /* SUSE specific hack - remain compatible with previously used socket path */ ++ xasprintf(&base, "/run/tmux/%ld", (long)uid); ++ } else { ++ path = paths[0]; /* can only have one socket! */ ++ for (i = 1; i < n; i++) ++ free(paths[i]); ++ free(paths); ++ xasprintf(&base, "%s/tmux-%ld", path, (long)uid); ++ free(path); + } +- path = paths[0]; /* can only have one socket! */ +- for (i = 1; i < n; i++) +- free(paths[i]); +- free(paths); +- +- xasprintf(&base, "%s/tmux-%ld", path, (long)uid); +- free(path); + if (mkdir(base, S_IRWXU) != 0 && errno != EEXIST) { + xasprintf(cause, "couldn't create directory %s (%s)", base, + strerror(errno)); +--- tmux-3.3/tmux.h 2022-05-14 21:04:35.000000000 +0200 ++++ tmux-3.3/tmux.h 2022-06-04 09:04:55.829136130 +0200 +@@ -74,7 +74,7 @@ + #define TMUX_CONF "/etc/tmux.conf:~/.tmux.conf" + #endif + #ifndef TMUX_SOCK +-#define TMUX_SOCK "$TMUX_TMPDIR:" _PATH_TMP ++#define TMUX_SOCK "$TMUX_TMPDIR:" + #endif + #ifndef TMUX_TERM + #define TMUX_TERM "screen" +Nur in b/tmux-3.3: tmux.h.orig. diff --git a/tmux.changes b/tmux.changes new file mode 100644 index 0000000..2a7fe37 --- /dev/null +++ b/tmux.changes @@ -0,0 +1,1249 @@ +------------------------------------------------------------------- +Tue May 2 15:37:28 UTC 2023 - Ondřej Súkup + +- add ncurses.patch for compactibility with new ncurses + fixes boo#1210552 + +------------------------------------------------------------------- +Fri Mar 10 10:44:22 UTC 2023 - Dirk Müller + +- disable utf8proc (following upstreams not use it by default + on non-macOS) + +------------------------------------------------------------------- +Mon Jan 23 16:17:36 UTC 2023 - pgajdos@suse.com + +- security update +- added patches + fix CVE-2022-47016 [bsc#1207393], Null pointer dereference in window.c + + tmux-CVE-2022-47016.patch + +------------------------------------------------------------------- +Mon Jul 25 22:24:54 UTC 2022 - Dirk Müller + +- switch to screen-256color as default terminal to fix incompatibility + with yast2-ruby-testsuite + +------------------------------------------------------------------- +Fri Jul 8 06:52:13 UTC 2022 - llyyr + +- update to 3.3a: + * Do not crash when run-shell produces output from a config file. + * Do not unintentionally turn off all mouse mode when button mode is also + present. + +------------------------------------------------------------------- +Sat Jun 4 07:12:46 UTC 2022 - Dirk Müller + +- update to 3.3: + * Add an ACL list for users connecting to the tmux socket. Users may be + forbidden from attaching, forced to attach read-only, or allowed to attach + read-write. A new command, server-access, configures the list. File system + permissions must still be configured manually. + * Emit window-layout-changed on swap-pane. + * Better error reporting when applying custom layouts. + * Handle ANSI escape sequences in run-shell output. + * Add pane_start_path to match start_command. + * Set PWD so shells have a hint about the real path. + * Do not allow pipe-pane on dead panes. + * Do not report mouse positions (incorrectly) above the maximum of 223 in + normal mouse mode. + * Add an option (default off) to control the passthrough escape sequence. + * Support more mouse buttons when the terminal sends them. + * Add a window-resized hook which is fired when the window is actually resized + which may be later than the client resize. + * Add next_session_id format with the next session ID. + * Add formats for client and server UID and user. + * Add argument to refresh-client -l to forward clipboard to a pane. + * Add remain-on-exit-format to set text shown when pane is dead. + * With split-window -f use percentages of window size not pane size. + * Add an option (fill-character) to set the character used for unused areas of + a client. + * Add an option (scroll-on-clear) to control if tmux scrolls into history on + clear. + * Add a capability for OSC 7 and use it similarly to how the title is set (and + controlled by the same set-titles option). + * Add support for systemd socket activation (where systemd creates the Unix + domain socket for tmux rather than tmux creating it). Build with + --enable-systemd. + * Add an option (pane-border-indicators) to select how the active pane is shown + on the pane border (colour, arrows or both). + * Support underscore styles with capture-pane -e. + * Make pane-border-format a pane option rather than window. + * Respond to OSC 4 queries + * Fix g/G keys in modes to do the same thing as copy mode (and vi). + * Bump the time terminals have to respond to device attributes queries to three + seconds. + * If automatic-rename is off, allow the rename escape sequence to set an empty + name. + * Trim menu item text more intelligently. + * Add cursor-style and cursor-colour options to set the default cursor style + and colour. + * Accept some useful and non-conflicting emacs keys in vi normal mode at the + command prompt. + * Add a format modifier (c) to force a colour to RGB. + * Add -s and -S to display-popup to set styles, -b to set lines and -T to set + popup title. New popup-border-lines, popup-border-style and popup-style + options set the defaults. + * Add -e flag to set an environment variable for a popup. + * Make send-keys without arguments send the key it is bound to (if bound to a + key). + * Try to leave terminal cursor at the right position even when tmux is drawing + its own cursor or selection (such as at the command prompt and in choose + mode) for people using screen readers and similar which can make use of it. + * Change so that {} is converted to tmux commands immediately when parsed. This + means it must contain valid tmux commands. For commands which expand %% and + %%%, this now only happens within string arguments. Use of nested aliases + inside {} is now forbidden. Processing of commands given in quotes remains + the same. + * Disable evports on SunOS since they are broken. + * Do not expand the file given with tmux -f so it can contain :s. + * Bump FORMAT_LOOP_LIMIT and add a log message when hit. + * Add a terminal feature for the mouse (since FreeBSD termcap does not have kmous). + * Forbid empty session names. + * Improve error reporting when the tmux /tmp directory cannot be created or + used. + * Give #() commands a one second grace period where the output is empty before + telling the user they aren't doing anything ("not ready"). + * When building, pick default-terminal from the first of tmux-256color, tmux, + screen-256color, screen that is available on the build system (--with-TERM + can override). + * Do not close popups on resize, instead adjust them to fit. + * Add a client-active hook. + * Make window-linked and window-unlinked window options. + * Do not configure on macOS without the user making a choice about utf8proc + (either --enable-utf8proc or --disable-utf8proc). + * Do not freeze output in panes when a popup is open, let them continue to + redraw. + * Add pipe variants of the line copy commands. + * Change copy-line and copy-end-of-line not to cancel and add -and-cancel + variants, like the other copy commands. + * Support the OSC palette-setting sequences in popups. + * Add a pane-colours array option to specify the defaults palette. + * Add support for Unicode zero-width joiner. + * Make newline a style delimiter as well so they can cross multiple lines for + readability in configuration files. + * Change focus to be driven by events rather than scanning panes so the + ordering of in and out is consistent. + * Add display-popup -B to open a popup without a border. + * Add a menu for popups that can be opened with button three outside the popup + or on the left or top border. Resizing now only works on the right and bottom + borders or when using Meta. The menu allows a popup to be closed, expanded to + the full size of the client, centered in the client or changed into a pane. + * Make command-prompt and confirm-before block by default (like run-shell). A + new -b flags runs them in the background as before. Also set return code for + confirm-before. + * Change cursor style handling so tmux understands which sequences contain + blinking and sets the flag appropriately, means that it works whether cnorm + disables blinking or not. This now matches xterm's behaviour. + * More accurate vi(1) word navigation in copy mode and on the status line. This + changes the meaning of the word-separators option: setting it to the empty + string is equivalent to the previous behavior. + * Add -F for command-prompt and use it to fix "Rename" on the window menu. + * Add different command histories for different types of prompts ("command", + "search" etc). +- tmux-socket-path.patch: refresh +- build with utf8proc enabled +- set default TERM to recommended tmux-256colors + +------------------------------------------------------------------- +Sat Jun 26 08:40:36 UTC 2021 - Andreas Stieger + +- update to 3.2a: + * Add an "always" value for the "extended-keys" option; if set + then tmux will forward extended keys to applications even if + they do not request them. + * Add a "mouse" terminal feature so tmux can enable the mouse on + terminals where it is known to be supported even if + terminfo(5) says otherwise. + * Do not expand the filename given to -f so it can contain + colons. + * Fixes for problems with extended keys and modifiers, scroll + region, source-file, crosscompiling, format modifiers and other + minor issues. + +------------------------------------------------------------------- +Sat May 8 08:48:53 UTC 2021 - Dirk Müller + +- refresh tmux-socket-path.patch: + restore ability to overwrite socket path using $TMUX_TMPDIR (bsc#1185572) + +------------------------------------------------------------------- +Sat Apr 17 20:56:38 UTC 2021 - Dirk Müller + +- update to 3.2: + * status-fg and status-bg are now applied before status-style rather than instead + of; this means that if either is set to default the status-style colour will be + used. To fix, replace status-bg default with status-style bg=default. + * How data is sent to control mode clients has been completely revamped to both + be more fair with multiple panes and to prevent huge amounts of data being + backed up; this feature is used by default when tmux is attached with the + latest iTerm2 nightly builds. + * Configuration file parsing has changed slightly: the contents of the new {} + syntax introduced in 3.1 must now be valid tmux command syntax; and to allow + formats to be annotated, strings given with quotes may now contain newlines + (leading spaces and comments are stripped). + * A new customize mode available with C-b C (C-b S-c) which allows options and + key bindings to be browsed and changed interactively. + * Support for extended keys offered by some terminals (xterm, mintty, iTerm2), + see https://github.com/tmux/tmux/wiki/Modifier-Keys#extended-keys. + * A pane-border-lines option to change the characters used to draw the pane + border separators. + * How UTF-8 data is stored has been rewritten to reduce memory use for characters + in the BMP. + * The message log (C-b ~) has been changed to be per server instead of per client + and to have some useful content. + * Client flags have been extended (refresh-client -F becomes -f and also added + for attach-session and new-session), and a read-only flag added (same as -r to + attach-session). + * A new active-pane client flag that if given allows a client to have its own + active pane for each window rather than being tied to the server's active pane. + * Improved command-prompt completion including showing a menu of completions. + * All style options can now be formats, for example the default + pane-active-border-style now changes colour depending on pane_in_mode and + synchronize-panes. + * Search match count has come back in copy mode, as well as performance + improvements and additional styles for marking of search terms. + * Try $XDG_CONFIG_HOME/tmux/tmux.conf as well as ~/.config/tmux/tmux.conf. + * Window and pane hooks such as window-layout-changed and pane-exited are now + window or pane options instead of session options. + * copy-pipe and friends can now be given with no arguments in which case they get + the command from a new copy-command option. The default copy commands all now + use copy-pipe. This makes it much easier to configure copy-pipe for all copy + key bindings. + * Terminal detection and feature code has been rewritten. tmux now collects sets + of related terminfo(5) capabilties together with sensible default values into + named "terminal features" which makes them easier to configure via a new + terminal-features option or -T flag to tmux itself. tmux can detect and will + automatically configure a number of common, modern terminal emulators. + * Support for per-client overlay popups with a new display-popup command. A popup + is also used for an e key binding in buffer mode to edit a buffer using the + editor given in the new editor option (filled in from the EDITOR or VISUAL + environment variables by default). + * DoubleClick and TripleClick mouse key bindings have changed so that only one is + fired. Behaviour similar to the old double-click key binding is now available + as SecondClick. There are now default double- and triple-click bindings to copy + a word or line, and a default middle-click binding to paste the top buffer. + * When a server socket is given with -S, it is now created with umask 177 rather + than 117. + +------------------------------------------------------------------- +Mon Nov 9 10:35:03 UTC 2020 - Dominique Leuenberger + +- Drop pkgconfig(systemd) BuildRequires: there is no reason to pull + in systemd into the build. +- Use %tmpfiles_create instead of calling systemd-tmpfiles + directly. +- Replace systemd_requires with systemd_ordering: tmux is very well + capable to run without systemd (and by using tmpfiles_create, the + post script can also cope with the absence of if). + +------------------------------------------------------------------- +Sat Oct 31 10:41:19 UTC 2020 - Andreas Stieger + +- fix build for SLE 12 PackageHub + +------------------------------------------------------------------- +Fri Oct 30 13:20:43 UTC 2020 - Ismail Dönmez + +- Update to version 3.1c + * Fix a stack overflow on colon-separated CSI parsing. + boo#1178263 CVE-2020-27347 + +------------------------------------------------------------------- +Tue May 5 08:44:13 UTC 2020 - Andreas Stieger + +- tmux 3.1b: + * Fix crash when allow-rename ison and an empty name is set + +------------------------------------------------------------------- +Thu Apr 30 07:31:37 UTC 2020 - Andreas Stieger + +- tmux 3.1a: + * Do not close stdout prematurely in control mode since it is + needed to print exit messages. Prevents hanging when detaching + with iTerm2 +- includes changes between 3.1-rc1 and 3.1: + * Only search the visible part of the history when marking + (highlighting) search terms. This is much faster than searching + the whole history and solves problems with large histories. The + count of matches shown is now the visible matches rather than + all matches + * Search using regular expressions in copy mode. search-forward + and search-backward use regular expressions by default; the + incremental versions do not + * Turn off mouse mode 1003 as well as the rest when exiting + * Add selection_active format for when the selection is present + but not moving with the cursor + * Fix dragging with modifier keys, so binding keys such as + C-MouseDrag1Pane and C-MouseDragEnd1Pane now work + * Add -a to list-keys to also list keys without notes with -N + * Do not jump to next word end if already on a word end when + selecting a word; fixes select-word with single character words + and vi(1) keys + * Fix top and bottom pane calculation with pane border status + enabled + +------------------------------------------------------------------- +Tue Feb 4 12:04:31 UTC 2020 - Ismail Dönmez + +- Update to v3.1-rc + * Please see the included CHANGES file + +------------------------------------------------------------------- +Wed Dec 4 16:22:13 UTC 2019 - Andreas Schneider + +- Fix tmux completion + +------------------------------------------------------------------- +Sun Dec 1 10:03:44 UTC 2019 - Ismail Dönmez + +- Update to v3.0a + * A lot of changes since v2.9a, please see the included CHANGES + file. + +------------------------------------------------------------------- +Fri Aug 23 13:06:07 UTC 2019 - Paolo Stivanin + +- Update to v2.9a + - Fix bugs in select-pane and the main-horizontal and main-vertical layouts. + +------------------------------------------------------------------- +Tue Jun 4 06:49:49 UTC 2019 - Aleksa Sarai + +- Add trailing newline to tmpfiles.d/tmux.conf. On newer systems (such as Leap + 15.1), the lack of a trailing newline appears to cause the directory to not + be created. + + This is only evident on setups where /run is an actual tmpfs (on btrfs-root + installs, /run is a btrfs subvolume and thus /run/tmux is persistent across + reboots). + +------------------------------------------------------------------- +Fri Apr 26 15:46:52 UTC 2019 - Ismail Dönmez + +- Update to version 2.9 + * Add format variables for the default formats in the various modes + (tree_mode_format and so on) and add a -a flag to display-message + to list variables with values. + * Add a -v flag to display-message to show verbose messages as the + format is parsed, this allows formats to be debugged + * Add support for HPA (\033[`). + * Add support for origin mode (\033[?6h). + * No longer clear history on RIS. + * Extend the #[] style syntax and use that together with previous + format changes to allow the status line to be entirely configured + with a single option. + * Add E: and T: format modifiers to expand a format twice + (useful to expand the value of an option). + * The individual -fg, -bg and -attr options have been removed; they + were superseded by -style options in tmux 1.9. + * Add -b to display-panes like run-shell. + * Handle UTF-8 in word-separators option. + * New "terminal" colour allowing options to use the terminal default + colour rather than inheriting the default from a parent option. + * Do not move the cursor in copy mode when the mouse wheel is used. + * Use the same working directory rules for jobs as new windows rather than + always starting in the user's home. + * Allow panes to be one line or column in size. + * Go to last line when goto-line number is out of range in copy mode. + * Yank previously cut text if any with C-y in the command prompt, only use the + buffer if no text has been cut. + * Add q: format modifier to quote shell special characters. + * Add -Z to find-window. + * Support for windows larger than the client. This adds two new options, + window-size and default-size, and a new command, resize-window. The + force-width and force-height options and the session_width and session_height + formats have been removed. +- Drop fix-cve201819387.patch, issue_1549.diff: Fixed upstream. + +------------------------------------------------------------------- +Fri Jan 4 12:32:29 UTC 2019 - Ondřej Súkup + +- add issue_1549.diff to fix boo#1120170 + +------------------------------------------------------------------- +Tue Nov 27 10:01:13 UTC 2018 - Ondřej Súkup + +- add fix-cve201819387.patch fixes CVE-2018-19387 boo#1116887 + +------------------------------------------------------------------- +Sat Oct 20 10:47:11 UTC 2018 - Ondřej Súkup + +- update to 2.8 +- drop 0001-Increment-the-lines-counter-when-skipping-a-line-to-.patch +- move bash-completion to right place + * Make display-panes block the client until a pane is chosen or it + times out. + * Clear history on RIS like most other terminals do. + * Add an "Any" key to run a command if a key is pressed that is not + bound in the current key table. + * Expand formats in load-buffer and save-buffer. + * Add a rectangle_toggle format. + * Add set-hook -R to run a hook immediately. + * Add pane focus hooks. + * Allow any punctuation as separator for s/x/y not only /. + * Improve resizing with the mouse (fix resizing the wrong pane in some + layouts, and allow resizing multiple panes at the same time). + * Allow , and } to be escaped in formats as #, and #}. + * Add KRB5CCNAME to update-environment. + * Change meaning of -c to display-message so the client is used if it + matches the session given to -t. + * Fixes to : form of SGR. + * Add x and X to choose-tree to kill sessions, windows or panes. + +------------------------------------------------------------------- +Fri Jun 15 10:06:14 UTC 2018 - BArendartchuk@suse.com + +- Add upstream + 0001-Increment-the-lines-counter-when-skipping-a-line-to-.patch fixing + infinite loop when resizing the window + +------------------------------------------------------------------- +Tue May 15 18:39:52 UTC 2018 - asn@cryptomilk.org + +- Add bash completion for tmux + +------------------------------------------------------------------- +Sun Apr 15 00:25:50 UTC 2018 - avindra@opensuse.org + +- Update to 2.7 + * Remove EVENT_* variables from environment on platforms where + tmux uses them so they do not pass on to panes. + * Fixed for hooks at server exit. + * Remove SGR 10 (was equivalent to SGR 0 but no other terminal + seems to do this). + * Expand formats in window and session names. + * Add -Z flag to choose-tree, choose-client, choose-buffer to + automatically zoom the pane when the mode is entered and unzoom + when it exits, assuming the pane is not already zoomed. This is + now part of the default key bindings. + * Add C-g to exit modes with emacs keys. + * Add exit-empty option to exit server if no sessions (default = on) + * Show if a filter is present in choose modes. + * Add pipe-pane -I to to connect stdin of the child process. + * Performance improvements for reflow. + * Use RGB terminfo(5) capability to detect RGB colour terminals + (the existing Tc extension remains unchanged). + * Support for ISO colon-separated SGR sequences. + * Add select-layout -E to spread panes out evenly (bound to E key). + * Support wide characters properly when reflowing. + * Pass PWD to new panes as a hint to shells, as well as calling + chdir(). + * Performance improvements for the various choose modes. + * Only show first member of session groups in tree mode (-G flag + to choose-tree to show all). + * Support %else in config files to match %if + * Fix "kind" terminfo(5) capability to be S-Down not S-Up. + * Add a box around the preview label in tree mode. + * Show exit status and time in the remain-on-exit pane text + * Correctly use pane-base-index in tree mode. + * Change the allow-rename option default to off. + * Support for xterm(1) title stack escape sequences + * Correctly remove padding cells to fix a UTF-8 display problem +- build from release tarball instead of source (drops automake dep) +- rebase tmux-socket-path.patch + +------------------------------------------------------------------- +Tue Oct 17 09:53:05 UTC 2017 - mimi.vx@gmail.com + +- update to 2.6 +* Add select-pane -T to set pane title. +* Fix memory leak when lines with BCE are removed from history. +* Fix (again) the "prefer unattached" behaviour of attach-session. +* Reorder how keys are checked to allow keys to be specified that have a + leading escape. GitHub issue 1048. +* Support REP escape sequence (\033[b). +* Run alert hooks based on options rather than always, and allow further bells + even if there is an existing bell. +* Add -d flag to display-panes to override display-panes-time. +* Add selection_present format when in copy mode (allows key bindings that do + something different if there is a selection). +* Add pane_at_left, pane_at_right, pane_at_top and pane_at_bottom formats. +* Make bell, activity and silence alerting more consistent by: removing the + bell-on-alert option; adding activity-action and silence-action options with + the same possible values as the existing bell-action; adding a "both" value + for the visual-bell, visual-activity and visual-silence options to trigger + both a bell and a message. +* Add a pane_pipe format to show if pipe-pane is active. +* Block signals between forking and resetting signal handlers so that the + libevent signal handler doesn't get called in the child and incorrectly write + into the signal pipe that it still shares with the parent. GitHub issue 1001. +* Allow punctuation in pane_current_command. +* Add -c for respawn-pane and respawn-window. +* Wait for any remaining data to flush when a pane is closed while pipe-pane is + in use. +* Fix working out current client with no target. GitHub issue 995. +* Try to fallback to C.UTF-8 as well as en_US.UTF-8 when looking for a UTF-8 + locale. +* Add user-keys option for user-defined key escape sequences (mapped to User0 + to User999 keys). +* Add pane-set-clipboard hook. +* FAQ file has moved out of repository to online. +* Fix problem with high CPU usage when a client dies unexpectedly. GitHub issue + 941. +* Do a dance on OS X 10.10 and above to return tmux to the user namespace, + allowing access to the clipboard. +* Do not allow escape sequences which expect a specific terminator (APC, DSC, + OSC) to wait for forever - use a small timeout. This reduces the chance of + the pane locking up completely when sent garbage (cat /dev/random or + similar). +* Support SIGUSR2 to toggle logging on a running server, also generate the + "out" log file with -vv not -vvvv. +* Make set-clipboard a three state option: on (tmux both sends to outside + terminal and accepts from applications inside); external (tmux sends outside + but does not accept inside); and off. +* Fix OSC 4 palette setting for bright foreground colours. GitHub issue 954. +* Use setrgbf and setrgbb terminfo(5) capabilities to set RGB colours, if they + are available. (Tc is still supported as well.) +* Fix redrawing panes when they are resized several times but end up with the + size unchanged (for example, splitw/resizep -Z/breakp). +* Major rewrite of choose mode. Now includes preview, sorting, searching and + tagging; commands that can be executed directly from the mode (for example, + to delete one or more buffers); and filtering in tree mode. +* choose-window and choose-session are now aliases of choose-tree (in the + command-alias option). +* Support OSC 10 and OSC 11 to set foreground and background colours. +* Check the U8 capability to determine whether to use UTF-8 line drawing + characters for ACS. +* Some missing notifications for layout changes. +* Control mode clients now do not affect session sizes until they issue + refresh-client -C. new-session -x and -y works with control clients even if + the session is not detached. +* All new sessions that are unattached (whether with -d or started with no + terminal) are now created with size 80 x 24. Whether the status line is on or + off does not affect the size of new sessions until they are attached. +* Expand formats in option names and add -F flag to expand them in option values. +* Remember the search string for a pane even if copy mode is exited and entered + again. +* Some further BCE fixes (scroll up, reverse index). +* Improvements to how terminals are cleared (entirely or partially). + +------------------------------------------------------------------- +Tue May 30 22:26:00 UTC 2017 - mimi.vx@gmail.com + +- update to 2.5 +- dropped tmux_issue889.patch +- refresh tmux-socket-path.patch +* new stable release + +------------------------------------------------------------------- +Wed May 3 17:58:33 UTC 2017 - mimi.vx@gmail.com + +- Fix boo#1037468 - tmux_issue889.patch + +------------------------------------------------------------------- +Fri Apr 21 06:12:25 UTC 2017 - asn@cryptomilk.org + +- Fix tmux-socket-path.patch to create directories inside of /run/tmux + +------------------------------------------------------------------- +Thu Apr 20 19:42:50 UTC 2017 - mimi.vx@gmail.com + +- update to 2.4 +- refresh tmux-socket-path.patch + + Incompatible Changes + * Key tables have undergone major changes. Mode key tables are no longer + separate from the main key tables. All mode key tables have been removed, + together with the -t flag to bind-key and unbind-key. + The emacs-edit, vi-edit, emacs-choose and vi-choose tables have been replaced + by fixed key bindings in the command prompt and choose modes. The mode-keys + and status-keys options remain. + The emacs-copy and vi-copy tables have been replaced by the copy-mode and + copy-mode-vi tables. Commands are sent using the -X and -N flags to + send-keys. So the following: + bind -temacs-copy C-Up scroll-up + bind -temacs-copy -R5 WheelUpPane scroll-up + Becomes: + bind -Tcopy-mode C-Up send -X scroll-up + bind -Tcopy-mode WheelUpPane send -N5 -X scroll-up + This changes allows the full command parser (including command sequences) and + command set to be used - for example, the normal command prompt with editing + and history is now used for searching, jumping, and so on instead of a custom + one. The default C-r binding is now: + bind -Tcopy-mode C-r command-prompt -p'search up' "send -X search-backward '%%'" + There are also some new commmands available with send -X, such as + copy-pipe-and-cancel. + * set-remain-on-exit has gone -- can be achieved with hooks instead. + * Hooks: before hooks have been removed and only a selection of commands now + have after hooks (they are no longer automatic). Additional hooks have been + added. + * The xterm-keys option now defaults to on. + + Normal Changes + * Support for mouse double and triple clicks. + * BCE (Background Colour Erase) is now supported. + * All occurrences of a search string in copy mode are now highlighted; + additionally, the number of search results is displayed. The highlighting + updates interactively with the default emacs key bindings (incremental + search). + * source-file now understands glob patterns. + * Formats now have simple comparisons: + #{==:a,b} + #{!=:a,b} + * There are the following new formats: + - #{version} -- the tmux server version; + - #{client_termtype} -- the terminal type of the client; + - #{client_name} -- the name of a client; + - #{client_written} -- the number of bytes written to the client. + * The configuration file now accepts %if/%endif conditional blocks which are + processed when it is parsed; the argument is a format string (useful with the + new format comparison options). + * detach-client now has -E to execute a command replacing the client instead of + exiting. + * Add support for custom command aliases, this is an array option which + contains items of the form "alias=command". This is consulted when an + unknown command is parsed. + * break-pane now has -n to specify the new window name. + * OSC 52 support has been added for programs inside tmux to set a tmux buffer. + * The mouse "all event" mode (1003) is now supported. + * Palette setting is now possible (OSC 4 and 104). + * Strikethrough support (a recent terminfo is required). + * Grouped sessions can now be named (new -t). + * terminal-overrides and update-environment are now array options (the previous + set -ag syntax should work without change). + * There have been substantial performance improvements. + +------------------------------------------------------------------- +Fri Sep 30 12:29:29 UTC 2016 - aloisio@gmx.com + +- Update to version 2.3 + * New option 'pane-border-status' to add text in the oane + borders. + * Support for hooks on commands: 'after' and 'before' hooks. + * 'source-file' understands '-q' to supress errors for + nonexistent files. + * Lots of UTF8 improvements, especially on MacOS. + * 'window-status-separator' understands #[] expansions. + * 'split-window' understands '-f' for performing a full-width + split. + * Allow report count to be specified when using 'bind-key -R'. + * 'set -a' for appending to user options (@foo) is now + supported. + * 'display-panes' can now accept a command to run, rather + than always selecting the pane. + +------------------------------------------------------------------- +Sun Apr 24 10:51:55 UTC 2016 - mpluskal@suse.com + +- Add correct systemd requires (boo#976922) + +------------------------------------------------------------------- +Tue Apr 12 07:44:49 UTC 2016 - idonmez@suse.com + +- Update to 2.2 + + Incompatible changes: + * The format strings which referenced time have been removed. Instead: + #{t:window_activity} can be used. + * Support for TMPDIR has been removed. Use TMUX_TMPDIR instead. + * UTF8 detection how happens automatically if the client supports it, hence + the mouse-utf8, utf8 options has been removed. + * The mouse_utf8_flag format string has been removed. + * The -I option to show-messages has been removed. See #{t:start_time} + format option instead. + + Other changes: + * Panes are unzoomed with selectp -LRUD + * New formats added: + #{scroll_position} + #{socket_path} + #{=10:...} -- limit to N characters (from the start) + #{=-10:...} -- limit to N characters (from the end) + #{t:...} -- used to format time-based formats + #{b:...} -- used to ascertain basename from string + #{d:...} -- used to ascertain dirname from string + #{s:...} -- used to perform substitutions on a string + * Job output is run via the format system, so formats work again + * If display-time is set to 0, then the indicators wait for a key to be + pressed. + * list-keys and list-commands can be run without starting the tmux server. + * kill-session learns -C to clear all alerts in all windows of the session. + * Support for hooks (internal for now), but hooks for the following have been + implemented: + alert-bell + alert-silence + alert-activity + client-attached + client-detached + client-resized + pane-died + pane-exited + * RGB (24bit) colour support. The 'Tc' flag must be set in the external TERM + entry (using terminal-overrides or a custom terminfo entry). +- Refresh tmux-socket-path.patch +- Bash completion is now removed and provided by + https://github.com/przepompownia/tmux-bash-completion instead. + +------------------------------------------------------------------- +Mon Feb 1 13:09:14 UTC 2016 - mimi.vx@gmail.com + +- cleanup specfile + +------------------------------------------------------------------- +Sun Jan 31 09:02:58 UTC 2016 - mpluskal@suse.com + +- Enable bash-completion support + +------------------------------------------------------------------- +Sun Oct 18 18:38:49 UTC 2015 - mimi.vx@gmail.com + +- update to 2.1 +- Incompatible Changes: +* Mouse-mode has been rewritten. There's now no longer options for: + - mouse-resize-pane + - mouse-select-pane + - mouse-select-window + - mode-mouse + Instead there is just one option: 'mouse' which turns on mouse support + entirely. +* 'default-terminal' is now a session option. Furthermore, if this is set + to 'screen-*' then emulate what screen does. If italics are wanted, this + can be set to 'tmux' but this is still new and not necessarily supported + on all platforms with older ncurses installs. +* The c0-* options for rate-limiting have been removed. Instead, a backoff + approach is used. +- Normal Changes: +* New formats: + - session_activity + - window_linked + - window_activity_format + - session_alerts + - session_last_attached + - client_pid + - pid +* 'copy-selection', 'append-selection', 'start-named-buffer' now understand + an '-x' flag to prevent it exiting copying mode. +* 'select-pane' now understands '-P' to set window/pane background colours. +* 'renumber-windows' now understands windows which are unlinked. +* 'bind' now understands multiple key tables. Allows for key-chaining. +* 'select-layout' understands '-o' to undo the last layout change. +* The environment is updated when switching sessions as well as attaching. +* 'select-pane' now understands '-M' for marking a pane. This marked pane + can then be used with commands which understand src-pane specifiers + automatically. +* If a session/window target is prefixed with '=' then only an exact match + is considered. +* 'move-window' understands '-a'. +* 'update-environment' understands '-E' when attach-session is used on an + already attached client. +* 'show-environment' understands '-s' to output Bourne-compatible commands. +* New option: 'history-file' to save/restore command prompt history. +* Copy mode is exited if the history is cleared whilst in copy-mode. +* 'copy-mode' learned '-e' to exit copy-mode when scrolling to end. + +------------------------------------------------------------------- +Fri Sep 18 22:13:32 UTC 2015 - pcerny@suse.com + +- enable build on SLE11 (requires libevent2) +- move comment to patch + +------------------------------------------------------------------- +Thu Jul 9 08:38:20 UTC 2015 - nemysis@gmx.ch + +- Revert remove patch tmux-socket-path.patch, deleted in previous commit. + use -p0 not -p1 + +------------------------------------------------------------------- +Tue Jul 7 10:46:57 UTC 2015 - nemysis@gmx.ch + +- Change Url from SourceForge to GitHub +- Change Source0 to usem new GitHub Web URL +- Add BuildRequires for automake +- Remove patch tmux-socket-path.patch +- Use sed instead of simple patch +- Change Documentation, add COPYING +- Use %{name} instead of tmux + +------------------------------------------------------------------- +Mon May 11 13:19:33 UTC 2015 - mrueckert@suse.de + +- guard all systemd specific code in a bcond systemd. this includes + buildrequires, patching the socket path and the tmpfiles.d + handling +- actually add a buildrequires for pkgconfig so we can use that for + libraries +- allow building on older distros which do not have + pkgconfig(ncurses) yet by requiring ncurses-devel there. +- make sure we buildrequire libevent >= 2.0 as tmux requires that + since 1.9 +- expand the make_install macro to make it work on distros without + the macro +- expand tmpfiles_create macro as it isnt defined on sle12 e.g. + +------------------------------------------------------------------- +Thu May 7 07:30:00 UTC 2015 - gber@opensuse.org + +- update to version 2.0 + - Incompatible changes: + - The choose-list command has been removed. + - 'terminal-overrides' is now a server option, not a session + option. + - 'message-limit' is now a server option, not a session option. + - 'monitor-content' option has been removed. + - 'pane_start_path' option has been removed. + - The "info" mechanism which used to (for some commands) + provide feedback has been removed, and like other commands, + they now produce nothing on success. + - Normal changes: + - tmux can now write an entry to utmp if the library 'utempter' + is present at compile time. + - set-buffer learned append mode (-a), and a corresponding + 'append-selection' command has been added to copy-mode. + - choose-mode now has the following commands which can be + bound: + - start-of-list + - end-of-list + - top-line + - bottom-line + - choose-buffer now understands UTF-8. + - Pane navigation has changed: + - The old way of always using the top or left if the choice + is ambiguous. + - The new way of remembering the last used pane is annoying + if the layout is balanced and the leftmost is obvious to + the user (because clearly if we go right from the + top-left in a tiled set of four we want to end up in + top-right, even if we were last using the bottom-right). + So instead, use a combination of both: if there is only + one possible pane alongside the current pane, move to it, + otherwise choose the most recently used of the choice. + - 'set-buffer' can now be told to give names to buffers. + - The 'new-session', 'new-window', 'split-window', and + 'respawn-pane' commands now understand multiple arguments and + handle quoting problems correctly. + - 'capture-pane' understands '-S-' to mean the start of the + pane, and '-E-' to mean the end of the pane. + - Support for function keys beyond F12 has changed. The + following explains: + - F13-F24 are S-F1 to S-F12 + - F25-F36 are C-F1 to C-F12 + - F37-F48 are C-S-F1 to C-S-F12 + - F49-F60 are M-F1 to M-F12 + - F61-F63 are M-S-F1 to M-S-F3 + Therefore, F13 becomes a binding of S-F1, etc. + - Support using pane id as part of session or window specifier + (so % means session-of-%1 or window-of-%1) and window id as + part of session + (so @1 means session-of-@1). + - 'copy-pipe' command now understands formats via -F + - 'if-shell' command now understands formats via -F + - 'split-window' and 'join-window' understand -b to create the + pane to the left or above the target pane. +- drop obsolete tmux-fix-malloc-check-abort.patch + +------------------------------------------------------------------- +Fri Nov 14 17:56:33 UTC 2014 - crrodriguez@opensuse.org + +- tmux-socket-path.patch: Just like screen, create socket + directory with tmpfiles.d functionality in /run/tmux + and not in /tmp. This patch only alters the default + directory that can be still overrriden by setting + TMUX_TMPDIR or TMPDIR environment variable. This add some + robustness against accidental deletion via + systemd-tmpfiles-clean, tmpwatch, or similar. + +------------------------------------------------------------------- +Thu Nov 13 15:22:12 UTC 2014 - tchvatal@suse.com + +- Add full download url for the tarball fetching/verification + +------------------------------------------------------------------- +Sun Nov 2 18:01:15 UTC 2014 - dmacvicar@suse.de + +- add tmux-fix-malloc-check-abort.patch in order to fix glibc + aborting on openSUSE Factory due toits MALLOC_CHECK_ settings + (http://sourceforge.net/p/tmux/tickets/105/, bnc#869950) + +------------------------------------------------------------------- +Sun Feb 23 22:28:14 UTC 2014 - gber@opensuse.org + +- update to version 1.9a + - Fix crash due to uninitialized lastwp member of layout_cell + - Fix -fg/-bg/-style with 256 colour terminals. + +------------------------------------------------------------------- +Thu Feb 20 22:18:42 UTC 2014 - gber@opensuse.org + +- update to version 1.9 + - NOTE: This release has bumped the tmux protocol version. It is + therefore advised that the prior tmux server is restarted when + this version of tmux is installed, to avoid protocol mismatch + errors for newer clients trying to talk to an older running + tmux server. + - 88 colour support has been removed. + - 'default-path' has been removed. The new-window command accepts + '-c' to cater for this. The previous value of "." can be + replaced with: 'neww -c $PWD', the previous value of '' which + meant current path of the pane can be specified as: 'neww -c + "#{pane_current_path}"' + - The single format specifiers: #A -> #Z (where defined) have + been deprecated and replaced with longer-named equivalents, as + listed in the FORMATS section of the tmux manpage. + - The various foo-{fg,bg,attr} commands have been deprecated and + replaced with equivalent foo-style option instead. Currently + this is still backwards-compatible, but will be removed over + time. + - A new environment variable TMUX_TMPDIR is now honoured, + allowing the socket directory to be set outside of TMPDIR + (/tmp/ if not set). + - If -s not given to swap-pane the current pane is assumed. + - A #{pane_syncronized} format specifier has been added to be a + conditional format if a pane is in a syncronised mode (c.f. + syncronize-panes) + - Tmux now runs under Cygwin natively. + - Formats can now be nested within each other and expanded + accordingly. + - Added 'automatic-rename-format' option to allow the automatic + rename mechanism to use something other than the default of + #{pane_current_command}. + - new-session learnt '-c' to specify the starting directory for + that session and all subsequent windows therein. + - The session name is now shown in the message printed to the + terminal when a session is detached. + - Lots more format specifiers have been added. + - Server race conditions have been fixed; in particular commands + are not run until after the configuration file is read + completely. + - Case insensitive searching in tmux's copy-mode is now possible. + - attach-session and switch-client learnt the '-t' option to + accept a window and/or a pane to use. + - Copy-mode is only exited if no selection is in progress. + - Paste key in copy-mode is now possible to enter text from the + clipboard. + - status-interval set to '0' now works as intended. + - tmux now supports 256 colours running under fbterm. + - Many bug fixes! + +------------------------------------------------------------------- +Tue Mar 26 21:57:13 UTC 2013 - gber@opensuse.org + +- update to version 1.8 + - incompatible change: layout redo/undo has been removed + - add halfpage up/down bindings to copy mode + - session choosing fixed to work with unattached sessions + - new window options window-status-last-{attr,bg,fg} to denote + the last window which was active + - scrolling in copy-mode now scrolls the region without moving + the mouse cursor + - run-shell learnt '-t' to specify the pane to use when + displaying output + - support for middle-click pasting + - choose-tree learns '-u' to start uncollapsed + - select-window learnt '-T; to toggle to the last window if it's + already current + - new session option 'assume-paste-time' for pasting text versus + key-binding actions + - choose-* commands now work outside of an attached client + - aliases are now shown for list-commands command + - status learns about formats + - free-form options can be set with set-option if prepended with + an '@' sign + - capture-pane learnt '-p' to send to stdout, and '-e' for + capturing escape sequences, and '-a' to capture the alternate + screen, and '-P' to dump pending output + - many new formats added (client_session, client_last_session, + etc.) + - control mode, which is a way for a client to send tmux commands + currently more useful to users of iterm2 + - resize-pane learnt '-x' and '-y' for absolute pane sizing + - config file loading now reports errors from all files which are + loaded via the 'source-file' command + - 'copy-pipe' mode command to copy selection and pipe the + selection to a command + - changes panes can now emit focus notifications for certain + applications which use those + - run-shell and if-shell now accept format placeholders + - resize-pane learnt '-Z' for zooming a pane temporarily + - new-session learnt '-A' to make it behave like attach-session + - set-option learnt '-o' to prevent setting an option which is + already set + - capture-pane and show-options learns '-q' to silence errors + - new command 'wait-for' which blocks a client until woken up + again + - resizing panes will now reflow the text inside them + - lots and lots of bug fixes, fixing memory-leaks, etc + - various manpage improvements + +------------------------------------------------------------------- +Sat Oct 13 15:47:07 UTC 2012 - gber@opensuse.org + +- update to version 1.7 + - tmux configuration files now support line-continuation with a + "\" at the end of a line + - new option status-position to move the status line to the top + or bottom of the screen + - enforce history-limit option when clearing the screen + - Give each window a unique id, like panes but prefixed with @ + - add pane id to each pane in layout description (while still + accepting the old form) + - provide defined ways to set the various default-path + possibilities: ~ for home directory, . for server start + directory, - for session start directory and empty for the + pane's working directory (the default). All can also be used as + part of a relative path (eg -/foo). Also provide -c flags to + neww and splitw to override default-path setting + - add -l flag to send-keys to send input literally (without + translating key names) + - allow a single option to be specified to show-options to show + just that option + - new command "move-pane" (like join-pane but allows the same + window) + - join-pane and move-pane commands learn "-b" option to place the + pane to the left or above + - support for bracketed-paste mode + - allow send-keys command to accept hex values + - add locking around "start-server" to avoid race-conditions + - break-pane learns -P/-F arguments for display formatting + - set-option learns "-q" to make it quiet, and not print out + anything + - copy mode learns "wrap-search" option + - add a simple form of output rate limiting by counting the + number of certain C0 sequences (linefeeds, backspaces, carriage + returns) and if it exceeds a threshold (current default + 250/millisecond), start to redraw the pane every 100 + milliseconds instead of making each change as it comes. Two + configuration options - c0-change-trigger and + c0-change-interval + - find-window learns new flags: "-C", "-N", "-T" to match + against either or all of a window's content, name, or title + Defaults to all three options if none specified + - find-window automatically selects the appropriate pane for the + found matches + - show-environment can now accept one option to show that + environment value + - exit mouse mode when end-of-screen reached when scrolling with + the mouse wheel + - select-layout learns -u and -U for layout history stacks + - kill-window, detach-client, kill-session all learn "-a" option + for killing all but the current thing specified + - move-window learns "-r" option to renumber window sequentially + in a session + - new session option "renumber-windows" to automatically renumber + windows in a session when a window is closed. (see + "move-window -r") + - only enter copy-mode on scroll up + - choose-* and list-* commands all use "-F" for format + specifiers + - when spawning external commands, the value from the + "default-shell" option is now used, rather than assuming + /bin/sh + - new choose-tree command to render window/sessions as a tree for + selection + - display-message learns new format options + - for linked-windows across sessions, all flags for that window + are now cleared across sessions + - lots and lots of bug fixes, fixing memory-leaks, etc + - various manpage improvements + +------------------------------------------------------------------- +Tue Jan 24 09:16:45 UTC 2012 - gber@opensuse.org + +- update to version 1.6 + - extend the mode-mouse option to add a third choice which means + the mouse does not enter copy mode + - add a -r flag to switch-client to toggle the client read-only + flag + - add pane-base-index option + - support \ for line continuation in the configuration file + - framework for more powerful formatting of command output and + use it for list-{panes,windows,sessions}; this allows more + descriptive replacements (such as #{session_name}) and + conditionals + - mark dead panes with some text saying they are dead + - reject $SHELL if it is not a full path + - add -S option to refresh-client to redraw status line + - add an else clause for if-shell + - try to resolve relative paths for loadb and saveb (first, using + client working directory, if any, then default-path or session + working directory) + - support for \e[3J to clear the history and send the + corresponding terminfo code (E3) before locking + - when in copy mode, make repeat count indicate buffer to + replace, if used + - add screen*:XT to terminal-overrides for tmux-in-tmux + - status-line message attributes added + - move word-separators to be a session rather than window option + - change the way the working directory for new processes is + discovered; if default-path isn't empty, it is used; otherwise, + if a new window is created from the command-line, the working + directory of the client is used; if not, platform specific code + is used to retrieve the current working directory of the + process in the active pane; if that fails, the directory where + the session was created is used, instead + - do not change the current pane if both + mouse-select-{pane,window} are enabled + - add \033[s and \033[u to save and restore cursor position + - allow $HOME to be used as default-path + - add CNL and CPL escape sequences + - calculate last position correctly for UTF-8 wide characters + - add an option allow-rename to disable the window rename escape + sequence + - attributes for each type of status-line alert (ie bell, content + and activity) added; therefore, remove the superfluous options + window-status-alert-{attr,bg,fg} + - add a -R flag to send-keys to reset the terminal + - add strings to allow the aixterm bright colours to be used when + configuring colours + - drop the ability to have a list of keys in the prefix in favour + of two separate options, prefix and prefix2 + - flag -2 added to send-prefix to send the secondary prefix key + - show pane size in top right of display panes mode + - some memory leaks plugged + - more command-prompt editing improvements + - various manpage improvements + - more Vi mode improvements + +------------------------------------------------------------------- +Sun Jul 10 08:24:13 UTC 2011 - gber@opensuse.org + +- update to version 1.5 + - support xterm mouse modes 1002 and 1003 + - add a -P option to new-window and split-window to print the new + window or pane index in target form (useful to pass it into + other commands) + - support for UTF-8 mouse input (\033[1005h) which was added in + xterm 262 + - accept colours of the hex form #ffffff and translate to the + nearest from the xterm(1) 256-colour set + - use TMPDIR if set + - support -x and -y for new-session to specify the initial size + of the window if created detached with -d + - make bind-key accept characters with the top-bit-set and print + them as octal + - set $TMUX without the session when background jobs are run + - add a -P option to detach to HUP the client's parent process + (usually causing it to exit as well) + - support passing through escape sequences to the underlying + terminal by using DCS with a "tmux;" prefix + - give each pane created in a tmux server a unique id (starting + from 0), put it in the TMUX_PANE environment variable and + accept it as a target + - allow a start and end line to be specified for capture-pane + which may be negative to capture part of the history + - add -a and -s options to lsp to list all panes in the server or + session respectively; likewise add -s to lsw + - change -t on display-message to be target-pane for the #[A-Z] + replacements and add -c as target-client + - the attach-session command now prefers the most recently used + unattached session + - add -s option to detach-client to detach all clients attached + to a session + - add -t to list-clients + - change window with mouse wheel over status line if + mouse-select-window is on + - when mode-mouse is on, automatically enter copy mode when the + mouse is dragged or the mouse wheel is used, also exit copy + mode when the mouse wheel is scrolled off the bottom + - provide #h character pair for short hostname (no domain) + - add a new option, mouse-resize-pane; when on, panes may be + resized by dragging their borders + - add three new copy-mode commands - select-line, copy-line, + copy-end-of-line + - support setting the xterm clipboard when copying from copy mode + using the xterm escape sequence for the purpose (if xterm is + configured to allow it) + - support xterm(1) cursor colour change sequences through + terminfo(5) Cc (set) and Cr (reset) extensions + - support DECSCUSR sequence to set the cursor style with two new + terminfo(5) extensions, Cs and Csr + - make the command-prompt custom prompts recognize the + status-left option character pairs + - add a respawn-pane command + - add a couple of extra xterm-style keys that gnome terminal + provides + - allow the initial context on prompts to be set with the new -I + option to command-prompt; include the current window and + session name in the prompt when renaming and add a new key + binding ($) for rename session + - option bell-on-alert added to trigger the terminal bell when + there is an alert + - change the list-keys format so that it shows the keys using + actual tmux commands which should be able to be directly copied + into the config file + - show full targets for lsp/lsw -a + - make confirm-before prompt customizable with -p option like + command-prompt and add the character pairs #W and #P to the + default kill-{pane,window} prompts + - vi mode improvements + - bugfixes + +------------------------------------------------------------------- +Tue Dec 28 00:46:52 UTC 2010 - gber@opensuse.org + +- update to version 1.4 + - flags -n and -p added to switch-client + - use UTF-8 line drawing characters on UTF-8 terminals + - new server option exit-unattached added + - new session option destroy-unattached added + - new command last-pane added + - flag -a added to unbind-key + - add XAUTHORITY to update-environment + - if VISUAL or EDITOR contains "vi" configure mode-keys and + status-key to vi + - new window option monitor-silence and session option + visual-silence added + - command-line flag -V added + - instead of keeping a per-client prompt history make it global + - flag -l added to switch-client + - new window options other-pane-{height,width} added + - bugfixes +- dropped tmux-1.1-fix-cflags-ldflags.patch + +------------------------------------------------------------------- +Mon Jul 19 10:28:49 UTC 2010 - guido+opensuse.org@berhoerster.name + +- update to version 1.3 + - new input parser + - new commands/flags/options were added/removed + - jump-forward/backward in copy move + - merged more mode into copy mode + - fixed double free when the window option remain-on-exit is + set + - custom/tiled layouts + - reworked signal handling + - allow dragging to make a selection in copy mode when the + mode-mouse option is set + - mouse scroll wheel support + - fixed problems with window sizing when starting tmux from + .xinitrc + - additional code reduction and bugfixes + +------------------------------------------------------------------- +Thu Mar 11 18:10:42 UTC 2010 - guido+opensuse.org@berhoerster.name + +- update to version 1.2 + - the code has been switched to libevent + - new commands/options were added + - the commands set-window-option, and show-window-options have been changed + to be aliases to set -w, and show -w respectively + - panes can now be referred to as top, bottom, top-left, etc. + - server-wide options have been added which can be set with set-option -s, + and shown with show-options -s + - permit S- prefix on keys for shift when the terminal/terminfo supports + them + - window targets (-t flag) can now refer to the last window (!), next (+), + and previous (-) window by number + - lots of mode keys added in copy mode + - there are additional code reductions, bug fixes, and manpage enhancements + +------------------------------------------------------------------- +Fri Feb 19 11:55:42 UTC 2010 - guido+opensuse.org@berhoerster.name + +- cleaned up specfile + +------------------------------------------------------------------- +Mon Feb 15 15:42:12 UTC 2010 - guido+opensuse.org@berhoerster.name + +- dropped patch and changes for creating sockets under /var/run, tmux thus does + not need to be setgid any more +- fixed copyright header and use external changelog + +------------------------------------------------------------------- +Mon Dec 21 00:00:00 UTC 2009 - guido+opensuse.org@berhoerster.name + +- rebased and combined patches for putting sockets under /var/run and dropping + setgid privileges + +------------------------------------------------------------------- +Mon Dec 21 00:00:00 UTC 2009 - guido+opensuse.org@berhoerster.name + +- initial packaging of tmux + diff --git a/tmux.spec b/tmux.spec new file mode 100644 index 0000000..291b6f6 --- /dev/null +++ b/tmux.spec @@ -0,0 +1,86 @@ +# +# spec file for package tmux +# +# Copyright (c) 2020 SUSE LLC +# +# All modifications and additions to the file contributed by third parties +# remain the property of their copyright owners, unless otherwise agreed +# upon. The license for this file, and modifications and additions to the +# file, is the same license as for the pristine package itself (unless the +# license for the pristine package is not an Open Source License, in which +# case the license is the MIT License). An "Open Source License" is a +# license that conforms to the Open Source Definition (Version 1.9) +# published by the Open Source Initiative. + +# Please submit bugfixes or comments via https://bugs.opensuse.org/ +# + + +Name: tmux +Version: 3.3a +Release: 0 +Summary: Terminal multiplexer +License: ISC AND BSD-3-Clause AND BSD-2-Clause +Group: System/Console +URL: https://tmux.github.io/ +Source0: https://github.com/tmux/tmux/releases/download/%{version}/%{name}-%{version}.tar.gz +Source1: bash_completion_tmux.sh +# PATCH-FIX-OPENSUSE crrodriguez@opensuse.org -- Use /run/tmux instead of /tmp as the default socket path, this add some robustness against accidental deletion via systemd-tmpfiles-clean, tmpwatch, or similar +Patch0: tmux-socket-path.patch +# CVE-2022-47016 [bsc#1207393], Null pointer dereference in window.c +Patch1: tmux-CVE-2022-47016.patch +# new ncurses secure interface fix +Patch2: ncurses.patch +BuildRequires: autoconf +BuildRequires: automake +BuildRequires: pkgconfig +BuildRequires: utempter-devel +BuildRequires: pkgconfig(libsystemd) +BuildRequires: pkgconfig(libevent) >= 2.0 +BuildRequires: pkgconfig(ncurses) +%{?systemd_ordering} + +%description +tmux is a terminal multiplexer: it enables a number of terminals (or windows), +each running a separate program, to be created, accessed, and controlled from a +single screen. tmux may be detached from a screen and continue running in the +background, then later reattached. tmux is intended to be a modern, +BSD-licensed alternative to programs such as GNU screen. + +tmux uses a client-server model. The server holds multiple sessions and each +window is a independent entity which may be freely linked to multiple sessions, +moved between sessions and otherwise manipulated. Each session may be attached +to (display and accept keyboard input from) multiple clients. + +%prep +%autosetup -p1 + +%build +export CFLAGS="%{optflags} -fno-strict-aliasing" +autoreconf +%configure --disable-utf8proc --with-TERM=screen-256color --enable-systemd +%make_build + +%install +%make_install + +# bash completion +install -d -m 0755 %{buildroot}%{_datadir}/bash-completion/completions/ +install -m 0644 %{SOURCE1} %{buildroot}%{_datadir}/bash-completion/completions/tmux + +install -d -m 0755 %{buildroot}%{_tmpfilesdir} +echo "d /run/tmux 1777 root root -" > %{buildroot}%{_tmpfilesdir}/tmux.conf + +%post +%tmpfiles_create %{_tmpfilesdir}/%{name}.conf + +%files +%license COPYING +%doc CHANGES +%{_datadir}/bash-completion/completions/tmux +%{_bindir}/%{name} +%{_mandir}/man1/%{name}.1%{?ext_man} +%{_tmpfilesdir}/%{name}.conf +%ghost /run/tmux + +%changelog