From: Mark Hatle <mark.hatle@windriver.com>
To: <openembedded-core@lists.openembedded.org>
Subject: Re: [PATCH] base-files: set dynamic COLUMNS via resize command
Date: Tue, 29 Jul 2014 08:43:27 -0500 [thread overview]
Message-ID: <53D7A4FF.2080303@windriver.com> (raw)
In-Reply-To: <1406624623-25774-1-git-send-email-ting.liu@freescale.com>
On 7/29/14, 4:03 AM, ting.liu@freescale.com wrote:
> From: Ting Liu <ting.liu@freescale.com>
>
> By default, COLUMNS is set to 80. If possible, run 'resize' to
> determine what the current dimensions are. This avoids the final
> part of long lines overlap the start of the same line.
>
> Signed-off-by: Ting Liu <ting.liu@freescale.com>
> ---
> meta/recipes-core/base-files/base-files/profile | 4 ++++
> 1 files changed, 4 insertions(+), 0 deletions(-)
>
> diff --git a/meta/recipes-core/base-files/base-files/profile b/meta/recipes-core/base-files/base-files/profile
> index 0b2d9d7..88ab8d8 100644
> --- a/meta/recipes-core/base-files/base-files/profile
> +++ b/meta/recipes-core/base-files/base-files/profile
> @@ -26,6 +26,10 @@ if [ -d /etc/profile.d ]; then
> unset i
> fi
>
> +if [ -x /usr/bin/resize ];then
> + /usr/bin/resize >/dev/null
> +fi
> +
Not sure how useful this is -- but -- the code should dynamically check for
${bindir} instead of hard code /usr/bin here. On many systems people collapse
'bindir' down to just '/bin'.
So my suggestion would be an accompanying do_install step that corrects this
reference if necessary.. something perhaps like:
if [ "/usr/bin" != "${bindir}" ]; then
sed -i /usr/bin/resize -e "s,/usr/bin/resize,${bindir}/resize,"
fi
I'll leave it to others to discuss the merit of adding resize. (I don't object
BTW).
> export PATH PS1 OPIEDIR QPEDIR QTDIR EDITOR TERM
>
> umask 022
>
next prev parent reply other threads:[~2014-07-29 13:43 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-07-29 9:03 [PATCH] base-files: set dynamic COLUMNS via resize command ting.liu
2014-07-29 13:43 ` Mark Hatle [this message]
2014-07-30 5:56 ` Khem Raj
2014-07-30 7:22 ` ting.liu
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=53D7A4FF.2080303@windriver.com \
--to=mark.hatle@windriver.com \
--cc=openembedded-core@lists.openembedded.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox