Use tmux with the Kerberos helper for the session alias.
alias kscreen=''
fi
unset krenew
-
- alias session='bigscreen -rx -S session || kscreen bigscreen -S session'
fi
unset screen
--- /dev/null
+# profile-requires: screen.bashrc
+# XXX: Use a module.
+tmux=$(PATH=$PATH:/comm/tmux/stable/bin find_working tmux 2>/dev/null)
+if [ $? = 0 ]; then
+ alias session="bigtmux $tmux has -t session 2>/dev/null && tmux attach -t session || ktmux -T $tmux -s session"
+ if [ -n "$TMUX" ]; then
+ $tmux run-shell ktmux_helper ';' detach 2>/dev/null
+ fi
+fi
--- /dev/null
+#!/bin/bash
+#
+# bigtmux: Start tmux, resizing the current window to allow a status line in
+# addition to an 87x24 display.
+# Usage: bigtmux [args]
+#
+
+# Resize only if we're at the default size.
+size=$(stty size)
+oldcols=${size##* }
+cols=${oldcols:-80}
+oldlines=${size%% *}
+lines=${oldlines:-24}
+
+[ ${lines:-24} -lt 25 ] && lines=25
+[ ${cols:-80} -lt 87 ] && cols=87
+[ $cols = $oldcols -a $lines = $oldlines ] || usize $cols $lines
+
+exec ${1+"$@"}
+