Openembedded Core Discussions
 help / color / mirror / Atom feed
* [PATCH] base-files: set dynamic COLUMNS via resize command
@ 2014-07-29  9:03 ting.liu
  2014-07-29 13:43 ` Mark Hatle
  2014-07-30  5:56 ` Khem Raj
  0 siblings, 2 replies; 4+ messages in thread
From: ting.liu @ 2014-07-29  9:03 UTC (permalink / raw)
  To: openembedded-core

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
+
 export PATH PS1 OPIEDIR QPEDIR QTDIR EDITOR TERM
 
 umask 022
-- 
1.7.3.4



^ permalink raw reply related	[flat|nested] 4+ messages in thread

* Re: [PATCH] base-files: set dynamic COLUMNS via resize command
  2014-07-29  9:03 [PATCH] base-files: set dynamic COLUMNS via resize command ting.liu
@ 2014-07-29 13:43 ` Mark Hatle
  2014-07-30  5:56 ` Khem Raj
  1 sibling, 0 replies; 4+ messages in thread
From: Mark Hatle @ 2014-07-29 13:43 UTC (permalink / raw)
  To: openembedded-core

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
>



^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: [PATCH] base-files: set dynamic COLUMNS via resize command
  2014-07-29  9:03 [PATCH] base-files: set dynamic COLUMNS via resize command ting.liu
  2014-07-29 13:43 ` Mark Hatle
@ 2014-07-30  5:56 ` Khem Raj
  2014-07-30  7:22   ` ting.liu
  1 sibling, 1 reply; 4+ messages in thread
From: Khem Raj @ 2014-07-30  5:56 UTC (permalink / raw)
  To: ting.liu; +Cc: Patches and discussions about the oe-core layer

On Tue, Jul 29, 2014 at 2:03 AM,  <ting.liu@freescale.com> wrote:
> 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.
>

what apps are showing these issues ?


^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: [PATCH] base-files: set dynamic COLUMNS via resize command
  2014-07-30  5:56 ` Khem Raj
@ 2014-07-30  7:22   ` ting.liu
  0 siblings, 0 replies; 4+ messages in thread
From: ting.liu @ 2014-07-30  7:22 UTC (permalink / raw)
  To: Khem Raj; +Cc: Patches and discussions about the oe-core layer

> -----Original Message-----
> From: Khem Raj [mailto:raj.khem@gmail.com]
> Sent: Wednesday, July 30, 2014 1:57 PM
> To: Liu Ting-B28495
> Cc: Patches and discussions about the oe-core layer
> Subject: Re: [OE-core] [oe-core][PATCH] base-files: set dynamic COLUMNS via
> resize command
> 
> On Tue, Jul 29, 2014 at 2:03 AM,  <ting.liu@freescale.com> wrote:
> > 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.
> >
> 
> what apps are showing these issues ?

Putty to login board via serial port.


^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2014-07-30  7:22 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2014-07-29  9:03 [PATCH] base-files: set dynamic COLUMNS via resize command ting.liu
2014-07-29 13:43 ` Mark Hatle
2014-07-30  5:56 ` Khem Raj
2014-07-30  7:22   ` ting.liu

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox