* byobu: don't create an extra shell, if the user has some default

windows specified


Signed-off-by: Dustin Kirkland <kirkland@canonical.com>
This commit is contained in:
Dustin Kirkland 2009-06-10 14:18:57 -05:00
commit 23438453b6
2 changed files with 11 additions and 3 deletions

9
byobu
View file

@ -88,6 +88,13 @@ sed -i "s/$OLDPKG/$PKG/g" "$HOME/.$PKG/keybindings"
# Ensure that their default windows are seeded
[ -r "$HOME/.$PKG/windows" ] || touch "$HOME/.$PKG/windows"
if grep -qs "^[^#]" "$HOME/.$PKG/windows"; then
# User has some default windows, so don't launch motd+shell
DEFAULT_WINDOW=
else
# User has no default windows, so launch motd+shell
DEFAULT_WINDOW="$SHELL /usr/bin/motd+shell"
fi
# Ensure that the user's $SCREENRC at least exists
[ -r "$SCREENRC" ] || touch "$SCREENRC"
@ -95,7 +102,7 @@ sed -i "s/$OLDPKG/$PKG/g" "$HOME/.$PKG/keybindings"
# Now let's execute screen!
if [ "$#" = "0" ]; then
[ -n "$SHELL" -a -x "$SHELL" ] || SHELL="/bin/sh"
exec $SCREEN_REAL -c "/usr/share/$PKG/profiles/byoburc" $SHELL /usr/bin/motd+shell
exec $SCREEN_REAL -c "/usr/share/$PKG/profiles/byoburc" $DEFAULT_WINDOW
else
exec $SCREEN_REAL -c "$HOME/.$PKG/profile" "$@"
fi

5
debian/changelog vendored
View file

@ -1,8 +1,9 @@
byobu (2.10) unreleased; urgency=low
* UNRELEASED
* byobu: don't create an extra shell, if the user has some default
windows specified
-- Dustin Kirkland <kirkland@ubuntu.com> Mon, 08 Jun 2009 17:56:10 -0500
-- Dustin Kirkland <kirkland@ubuntu.com> Wed, 10 Jun 2009 14:18:23 -0500
byobu (2.9-0ubuntu1) karmic; urgency=low