From owner-svn-src-stable-11@freebsd.org Tue Nov 14 17:03:57 2017 Return-Path: Delivered-To: svn-src-stable-11@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id D0E06DD7803; Tue, 14 Nov 2017 17:03:57 +0000 (UTC) (envelope-from trasz@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id A7303660DF; Tue, 14 Nov 2017 17:03:57 +0000 (UTC) (envelope-from trasz@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id vAEH3uq2047975; Tue, 14 Nov 2017 17:03:56 GMT (envelope-from trasz@FreeBSD.org) Received: (from trasz@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id vAEH3umV047971; Tue, 14 Nov 2017 17:03:56 GMT (envelope-from trasz@FreeBSD.org) Message-Id: <201711141703.vAEH3umV047971@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: trasz set sender to trasz@FreeBSD.org using -f From: Edward Tomasz Napierala Date: Tue, 14 Nov 2017 17:03:56 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-11@freebsd.org Subject: svn commit: r325814 - in stable/11: etc/root share/skel X-SVN-Group: stable-11 X-SVN-Commit-Author: trasz X-SVN-Commit-Paths: in stable/11: etc/root share/skel X-SVN-Commit-Revision: 325814 X-SVN-Commit-Repository: base MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-stable-11@freebsd.org X-Mailman-Version: 2.1.25 Precedence: list List-Id: SVN commit messages for only the 11-stable src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 14 Nov 2017 17:03:57 -0000 Author: trasz Date: Tue Nov 14 17:03:56 2017 New Revision: 325814 URL: https://svnweb.freebsd.org/changeset/base/325814 Log: MFC r320672: Run "resizewin -z" from the default shell profile files. This makes the terminal work properly out of the box when logging over a serial line, which is quite important for the user experience on boards like Raspberry Pi. It doesn't affect cases where the terminal size is already non-zero, such as SSH or vt(4) sessions. Note that this doesn't handle a scenario pointed out by rgrimes@: when the terminal is resized after login, the terminal size won't get updated even after logging out and back in. Modified: stable/11/etc/root/dot.login stable/11/etc/root/dot.profile stable/11/share/skel/dot.login stable/11/share/skel/dot.profile Directory Properties: stable/11/ (props changed) Modified: stable/11/etc/root/dot.login ============================================================================== --- stable/11/etc/root/dot.login Tue Nov 14 16:47:05 2017 (r325813) +++ stable/11/etc/root/dot.login Tue Nov 14 17:03:56 2017 (r325814) @@ -5,5 +5,8 @@ # see also csh(1), environ(7). # +# Query terminal size; useful for serial lines. +if ( -x /usr/bin/resizewin ) /usr/bin/resizewin -z + # Uncomment to display a random cookie each login: # if ( -x /usr/bin/fortune ) /usr/bin/fortune -s Modified: stable/11/etc/root/dot.profile ============================================================================== --- stable/11/etc/root/dot.profile Tue Nov 14 16:47:05 2017 (r325813) +++ stable/11/etc/root/dot.profile Tue Nov 14 17:03:56 2017 (r325814) @@ -8,3 +8,5 @@ TERM=${TERM:-xterm} export TERM PAGER=more export PAGER + +if [ -x /usr/bin/resizewin ] ; then /usr/bin/resizewin -z ; fi Modified: stable/11/share/skel/dot.login ============================================================================== --- stable/11/share/skel/dot.login Tue Nov 14 16:47:05 2017 (r325813) +++ stable/11/share/skel/dot.login Tue Nov 14 17:03:56 2017 (r325814) @@ -5,4 +5,5 @@ # see also csh(1), environ(7). # +if ( -x /usr/bin/resizewin ) /usr/bin/resizewin -z if ( -x /usr/bin/fortune ) /usr/bin/fortune freebsd-tips Modified: stable/11/share/skel/dot.profile ============================================================================== --- stable/11/share/skel/dot.profile Tue Nov 14 16:47:05 2017 (r325813) +++ stable/11/share/skel/dot.profile Tue Nov 14 17:03:56 2017 (r325814) @@ -21,4 +21,7 @@ PAGER=more; export PAGER # set ENV to a file invoked each time sh is started for interactive use. ENV=$HOME/.shrc; export ENV +# Query terminal size; useful for serial lines. +if [ -x /usr/bin/resizewin ] ; then /usr/bin/resizewin -z ; fi + if [ -x /usr/bin/fortune ] ; then /usr/bin/fortune freebsd-tips ; fi