diff --git a/debian/changelog b/debian/changelog index d1172495..b3ab0029 100644 --- a/debian/changelog +++ b/debian/changelog @@ -1,6 +1,8 @@ byobu (4.17) unreleased; urgency=low - * UNRELEASED + * usr/bin/byobu-launch: LP: #802646 + - ensure that .profile gets sourced if launching byobu by default, + but also make sure that we won't recurse! -- Dustin Kirkland Mon, 27 Jun 2011 14:14:17 +0000 diff --git a/usr/bin/byobu-launch b/usr/bin/byobu-launch index 05c37125..d1095c95 100755 --- a/usr/bin/byobu-launch +++ b/usr/bin/byobu-launch @@ -37,6 +37,10 @@ if [ "$LC_BYOBU" != "0" ] && [ "$BYOBU_DISABLE" != "1" ]; then # Attempt to merge shell history across sessions/windows (works with a few exceptions) shopt -s histappend || true [ -n "$PROMPT_COMMAND" ] && PROMPT_COMMAND="$PROMPT_COMMAND;history -a" || PROMPT_COMMAND="history -a" + # Source profile, as long as we won't recurse + if [ -r "$HOME/.profile" ]; then + (sed -e "s/#.*//" "$HOME/.profile" | grep -qs "$PKG-launch") || . "$HOME/.profile" + fi if byobu-launcher; then # Wait very briefly for the no-logout flag to get written? sleep 0.1