zsh-users
 help / color / mirror / code / Atom feed
* weird problems with zsh
@ 2001-07-19 14:29 oleg dashevskii
  2001-07-19 16:19 ` Paul Lew
                   ` (2 more replies)
  0 siblings, 3 replies; 5+ messages in thread
From: oleg dashevskii @ 2001-07-19 14:29 UTC (permalink / raw)
  To: zsh-users

hello!

for some case or another when I type into the command line 

% perl -e "print 'aaa'"

it outputs nothing, as opposed to bash which lets perl output 'aaa'

I experience the same problem with /usr/bin/printf, which isn't going to output anything

I've tried to remove all my ~/.zsh* config files, without success

I use FreeBSD 4.3-STABLE that of Jul 8 2001

~% zsh --version
zsh 4.0.1 (i386--freebsd4.3)

zsh has been built from ports

@leg

p.s. I'm not subscribed to the list, so please crosspost your reply to me.


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

* RE: weird problems with zsh
  2001-07-19 14:29 weird problems with zsh oleg dashevskii
@ 2001-07-19 16:19 ` Paul Lew
  2001-07-19 16:20 ` Erik Trulsson
  2001-07-19 16:22 ` Peter Stephenson
  2 siblings, 0 replies; 5+ messages in thread
From: Paul Lew @ 2001-07-19 16:19 UTC (permalink / raw)
  To: oleg dashevskii; +Cc: zsh-users

>>>>> "oleg" == oleg dashevskii <od@iclub.nsu.ru> writes:

    oleg> hello!  for some case or another when I type into the
    oleg> command line

    oleg> % perl -e "print 'aaa'"

    oleg> it outputs nothing, as opposed to bash which lets perl
    oleg> output 'aaa'

You need to add '\n' to the print, otherwise, the output displayed
will be overwritten by the zsh prompt.  You can try to add an echo
command at the end to see what I meant:

    % perl -e "print 'aaa'"; echo ""


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

* Re: weird problems with zsh
  2001-07-19 14:29 weird problems with zsh oleg dashevskii
  2001-07-19 16:19 ` Paul Lew
@ 2001-07-19 16:20 ` Erik Trulsson
  2001-07-19 16:22 ` Peter Stephenson
  2 siblings, 0 replies; 5+ messages in thread
From: Erik Trulsson @ 2001-07-19 16:20 UTC (permalink / raw)
  To: oleg dashevskii; +Cc: zsh-users

On Thu, Jul 19, 2001 at 09:29:12PM +0700, oleg dashevskii wrote:
> hello!
> 
> for some case or another when I type into the command line 
> 
> % perl -e "print 'aaa'"
> 
> it outputs nothing, as opposed to bash which lets perl output 'aaa'
> 
> I experience the same problem with /usr/bin/printf, which isn't going to output anything
> 
> I've tried to remove all my ~/.zsh* config files, without success
> 
> I use FreeBSD 4.3-STABLE that of Jul 8 2001
> 
> ~% zsh --version
> zsh 4.0.1 (i386--freebsd4.3)
> 
> zsh has been built from ports
> 
> @leg
> 
> p.s. I'm not subscribed to the list, so please crosspost your reply to me.
> 

It works fine for me, using FreeBSD 4.3-STABLE and zsh 4.0.2 from
ports.
I think it works fine for you too, you just don't see it :-)

What happens is that perl prints 'aaa' as it should and then zsh
regains control and prints the prompt.
This prompt overwrites the 'aaa'.

Bash apparently does not return the cursor to the leftmost column
before printing the prompt while zsh does.

Solution: Make sure that your output ends with a newline.
Eg.
perl -e "print 'aaa'" ; echo

This should give the expected result.

(You might try to replace the 'echo' on the line above with 'sleep 5'
to observe what happens. This will let the 'aaa' be displayed for 5
seconds before it is overwritten by zsh's prompt.)



-- 
<Insert your favourite quote here.>
Erik Trulsson
ertr1013@student.uu.se


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

* Re: weird problems with zsh
  2001-07-19 14:29 weird problems with zsh oleg dashevskii
  2001-07-19 16:19 ` Paul Lew
  2001-07-19 16:20 ` Erik Trulsson
@ 2001-07-19 16:22 ` Peter Stephenson
  2 siblings, 0 replies; 5+ messages in thread
From: Peter Stephenson @ 2001-07-19 16:22 UTC (permalink / raw)
  To: oleg dashevskii, Zsh users list

oleg dashevskii wrote:
> hello!
> 
> for some case or another when I type into the command line 
> 
> % perl -e "print 'aaa'"
> 
> it outputs nothing, as opposed to bash which lets perl output 'aaa'

It's the same as the following from the FAQ (though you might not
immediately realise that it was the prompt deleting back to the first
column, which it is).


3.23: How do I prevent the prompt overwriting output when there is no newline?

  The problem is, for example,

    % echo -n foo
    % 

  and the foo has been overwritten by the prompt %.  The answer is
  simple:  put unsetopt promptcr in your .zshrc.  The option PROMPT_CR,
  to print a carriage return before a new prompt, is set by default because
  a prompt at the right hand side (`$RPROMPT', `$RPS1') will not appear
  in the right place, and multi-line editing will be confused about the line
  position, unless the line starts in the left hand column.  Apart from
  PROMPT_CR, you can force this to happen by putting a newline in the
  prompt (see question 3.13 for that).

-- 
Peter Stephenson <pws@csr.com>                  Software Engineer
CSR Ltd., Unit 300, Science Park, Milton Road,
Cambridge, CB4 0XL, UK                          Tel: +44 (0)1223 392070


**********************************************************************
The information transmitted is intended only for the person or
entity to which it is addressed and may contain confidential 
and/or privileged material. 
Any review, retransmission, dissemination or other use of, or
taking of any action in reliance upon, this information by 
persons or entities other than the intended recipient is 
prohibited.  
If you received this in error, please contact the sender and 
delete the material from any computer.
**********************************************************************


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

* RE: weird problems with zsh
@ 2001-07-19 16:20 Murphy, Morgan
  0 siblings, 0 replies; 5+ messages in thread
From: Murphy, Morgan @ 2001-07-19 16:20 UTC (permalink / raw)
  To: od, zsh-users

Oleg,

>From The FAQ (How do I prevent the prompt from overwriting output when there
is no newline):
"The answer is simple: put unsetopt promptcr in your .zshrc"


Regards,
Morgan

-----Original Message-----
From: oleg dashevskii [mailto:od@iclub.nsu.ru]
Sent: Thursday, July 19, 2001 7:29 AM
To: zsh-users@sunsite.dk
Subject: weird problems with zsh


hello!

for some case or another when I type into the command line 

% perl -e "print 'aaa'"

it outputs nothing, as opposed to bash which lets perl output 'aaa'

I experience the same problem with /usr/bin/printf, which isn't going to
output anything

I've tried to remove all my ~/.zsh* config files, without success

I use FreeBSD 4.3-STABLE that of Jul 8 2001

~% zsh --version
zsh 4.0.1 (i386--freebsd4.3)

zsh has been built from ports

@leg

p.s. I'm not subscribed to the list, so please crosspost your reply to me.


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

end of thread, other threads:[~2001-07-19 16:28 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2001-07-19 14:29 weird problems with zsh oleg dashevskii
2001-07-19 16:19 ` Paul Lew
2001-07-19 16:20 ` Erik Trulsson
2001-07-19 16:22 ` Peter Stephenson
2001-07-19 16:20 Murphy, Morgan

Code repositories for project(s) associated with this public inbox

	https://git.vuxu.org/mirror/zsh/

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).