mirror of
https://github.com/dustinkirkland/byobu
synced 2025-08-21 22:13:19 -07:00
* motd+shell, screen: clean up temp file
Signed-off-by: Dustin Kirkland <kirkland@canonical.com>
This commit is contained in:
parent
77871bf796
commit
7a40cd6b01
3 changed files with 5 additions and 4 deletions
3
debian/changelog
vendored
3
debian/changelog
vendored
|
@ -2,8 +2,9 @@ screen-profiles (1.53) unreleased; urgency=low
|
|||
|
||||
* screen: some users gripe about the default launched window being
|
||||
called "motd+shell", LP: #369397
|
||||
* motd+shell, screen: clean up temp file
|
||||
|
||||
-- Dustin Kirkland <kirkland@ubuntu.com> Wed, 29 Apr 2009 15:59:51 -0500
|
||||
-- Dustin Kirkland <kirkland@ubuntu.com> Wed, 29 Apr 2009 16:11:29 -0500
|
||||
|
||||
screen-profiles (1.52-0ubuntu1) karmic; urgency=low
|
||||
|
||||
|
|
|
@ -18,4 +18,5 @@
|
|||
# along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
|
||||
[ -r /etc/motd ] && cat /etc/motd
|
||||
[ -n "$1" -a -w "$1" ] && rm -f "$1" 2>/dev/null
|
||||
[ -n "$SHELL" -a -x "$SHELL" ] && exec "$SHELL" || exec /bin/sh
|
||||
|
|
5
screen
5
screen
|
@ -81,11 +81,10 @@ fi
|
|||
if [ "$#" = "0" ]; then
|
||||
# Create a temporary config file *with* the default windows
|
||||
# but if we refresh, we'll just source the profile, without
|
||||
temp=$(mktemp screen-profiles-XXXXXXXX)
|
||||
trap "rm -f $temp 2>/dev/null || true" EXIT HUP INT QUIT TERM
|
||||
temp=$(mktemp -t screen-profiles-XXXXXXXX)
|
||||
cat "$HOME/.screen-profiles/profile" "$HOME/.screen-profiles/windows" > "$temp"
|
||||
[ -n "$SHELL" -a -x "$SHELL" ] || SHELL="/bin/sh"
|
||||
exec /usr/bin/screen.real -c "$temp" $SHELL /usr/bin/motd+shell
|
||||
exec /usr/bin/screen.real -c "$temp" $SHELL /usr/bin/motd+shell "$temp"
|
||||
else
|
||||
exec /usr/bin/screen.real -c "$HOME/.screen-profiles/profile" "$@"
|
||||
fi
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue