* byobu, byobu-launcher:

- set the window title to "$USER@HOST - byobu"
    - do this in byobu, rather than byobu-launcher so that all byobu
      sessions, and not just auto-launched sessions get this
    - note that we're dropping $PWD since this does not actually work
      and replacing this with " - byobu"
    - for $PWD to work, we'd need screen to support two separate
      hardstatus lines, as we can either put it at the bottom of byobu,
      or in the window title, and hardstatus is the only tool available
      to us for tracking $PWD
    - drop the bash -i hack in byobu-launcher; this speeds up logins
  [ Kees Cook ]


Signed-off-by: Dustin Kirkland <kirkland@canonical.com>
This commit is contained in:
Dustin Kirkland 2009-07-22 21:32:30 -05:00
commit 996a790915
3 changed files with 16 additions and 8 deletions

3
byobu
View file

@ -36,6 +36,9 @@ fi
# Sanitize the environment # Sanitize the environment
byobu-janitor --force byobu-janitor --force
# Set window title until https://bugs.launchpad.net/bugs/338722 is fixed in screen
echo -ne "\033]0;${USER}@$(hostname) - byobu\007"
# Launch motd+shell, unless the user has default windows set to launch # Launch motd+shell, unless the user has default windows set to launch
[ -n "$SHELL" ] || SHELL="/bin/sh" [ -n "$SHELL" ] || SHELL="/bin/sh"
[ -x "$SHELL" ] || SHELL="/bin/sh" [ -x "$SHELL" ] || SHELL="/bin/sh"

View file

@ -18,14 +18,8 @@
# You should have received a copy of the GNU General Public License # You should have received a copy of the GNU General Public License
# along with this program. If not, see <http://www.gnu.org/licenses/>. # along with this program. If not, see <http://www.gnu.org/licenses/>.
[ "$TERM" = "screen" ] && exit 0 [ "$TERM" = "screen" ] && exit 0
# Ensure that the PROMPT_COMMAND gets printed, such that gnome-terminal
# and friends can pick it up before going into screen
export PROMPT_COMMAND='echo -ne "\033]0;${USER}@${HOSTNAME}: ${PWD/$HOME/~}\007"'
[ -x /bin/bash ] && echo | /bin/bash -i -s 2>/dev/null
out=`screen -ls 2>/dev/null` || true out=`screen -ls 2>/dev/null` || true
if echo "$out" | grep -qsi "^No Sockets found in "; then if echo "$out" | grep -qsi "^No Sockets found in "; then
# Start new byobu session # Start new byobu session

15
debian/changelog vendored
View file

@ -1,8 +1,19 @@
byobu (2.23) unreleased; urgency=low byobu (2.23) unreleased; urgency=low
* UNRELEASED [ Kees Cook ]
* byobu, byobu-launcher:
- set the window title to "$USER@HOST - byobu"
- do this in byobu, rather than byobu-launcher so that all byobu
sessions, and not just auto-launched sessions get this
- note that we're dropping $PWD since this does not actually work
and replacing this with " - byobu"
- for $PWD to work, we'd need screen to support two separate
hardstatus lines, as we can either put it at the bottom of byobu,
or in the window title, and hardstatus is the only tool available
to us for tracking $PWD
- drop the bash -i hack in byobu-launcher; this speeds up logins
-- Dustin Kirkland <kirkland@ubuntu.com> Wed, 22 Jul 2009 19:41:42 -0500 -- Dustin Kirkland <kirkland@ubuntu.com> Wed, 22 Jul 2009 21:26:42 -0500
byobu (2.22-0ubuntu1) karmic; urgency=low byobu (2.22-0ubuntu1) karmic; urgency=low