zsh-workers
 help / color / mirror / code / Atom feed
* Bug report: Pasting content overwrites the current line and duplicates the text
@ 2021-09-07 22:58 Christopher Stead
  2021-09-07 23:16 ` Bart Schaefer
  2021-09-08  8:56 ` Roman Perepelitsa
  0 siblings, 2 replies; 4+ messages in thread
From: Christopher Stead @ 2021-09-07 22:58 UTC (permalink / raw)
  To: zsh-workers

[-- Attachment #1: Type: text/plain, Size: 969 bytes --]

Hi, I [read here](https://zsh.sourceforge.io/FAQ/zshfaq06.html#l62) that bug reports should go to this address. If this is incorrect, please direct me elsewhere.

Tested using Zsh version 5.8

IssuePasting text into the terminal results in the current line between wiped and replaced with the copied contents duplicated.

Scenario:

- Let's say the current terminal line looks like this:
~/work ❯ this is the current line

- I copy the word "current" and paste at the end of the line (with a space).

- Instead of ending up with:
~/work ❯ this is the current line current

I end up with this instead:
~/work ❯ currentcurrent

Causes
I have so far figured out that the following two commands cause this issue:

- set -a
- set -o allexport

I have tried this on two separate Zsh installations, one using Ubuntu in Windows Terminal, the other on an Ubuntu OS terminal - both to same effect.

If any further information is needed, please let me know.

Regards,

Chris

[-- Attachment #2: Type: text/html, Size: 1699 bytes --]

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

* Re: Bug report: Pasting content overwrites the current line and duplicates the text
  2021-09-07 22:58 Bug report: Pasting content overwrites the current line and duplicates the text Christopher Stead
@ 2021-09-07 23:16 ` Bart Schaefer
  2021-09-08  8:56 ` Roman Perepelitsa
  1 sibling, 0 replies; 4+ messages in thread
From: Bart Schaefer @ 2021-09-07 23:16 UTC (permalink / raw)
  To: Christopher Stead; +Cc: zsh-workers

On Tue, Sep 7, 2021 at 3:58 PM Christopher Stead <crstead@pm.me> wrote:
>
> I copy the word "current" and paste at the end of the line (with a space).

Copy and paste how?  Are you using the terminal's copy-paste mechanism
or the zsh line editor?

> I have so far figured out that the following two commands cause this issue:
>
> set -a
> set -o allexport

Are you able to reproduce this starting from "zsh -f", or only after
loading your initialization?  The example prompt you showed would
indicate you are doing some setup.


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

* Re: Bug report: Pasting content overwrites the current line and duplicates the text
  2021-09-07 22:58 Bug report: Pasting content overwrites the current line and duplicates the text Christopher Stead
  2021-09-07 23:16 ` Bart Schaefer
@ 2021-09-08  8:56 ` Roman Perepelitsa
  2021-09-08  9:31   ` Christopher Stead
  1 sibling, 1 reply; 4+ messages in thread
From: Roman Perepelitsa @ 2021-09-08  8:56 UTC (permalink / raw)
  To: Christopher Stead; +Cc: zsh-workers

On Wed, Sep 8, 2021 at 12:58 AM Christopher Stead <crstead@pm.me> wrote:
>
> Pasting text into the terminal results in the current line between
> wiped and replaced with the copied contents duplicated.
> I have tried this on two separate Zsh installations, one using Ubuntu
> in Windows Terminal, the other on an Ubuntu OS terminal - both to same effect.

This usually happens when the value of TERM environment variable is
incorrect. What do you get if you execute the following command?

    typeset -p TERM

In Windows Terminal and GNOME Terminal the correct output is this:

    export TERM=xterm-256color

If you are getting any other output, that's the problem.

Roman.


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

* Re: Bug report: Pasting content overwrites the current line and duplicates the text
  2021-09-08  8:56 ` Roman Perepelitsa
@ 2021-09-08  9:31   ` Christopher Stead
  0 siblings, 0 replies; 4+ messages in thread
From: Christopher Stead @ 2021-09-08  9:31 UTC (permalink / raw)
  To: Roman Perepelitsa; +Cc: zsh-workers

> What do you get if you execute the following command?
>
> typeset -p TERM

I get the expected output: export TERM=xterm-256color

‐‐‐‐‐‐‐ Original Message ‐‐‐‐‐‐‐

On Wednesday, September 8th, 2021 at 8:56 PM, Roman Perepelitsa <roman.perepelitsa@gmail.com> wrote:

> On Wed, Sep 8, 2021 at 12:58 AM Christopher Stead crstead@pm.me wrote:
>
> > Pasting text into the terminal results in the current line between
> >
> > wiped and replaced with the copied contents duplicated.
> >
> > I have tried this on two separate Zsh installations, one using Ubuntu
> >
> > in Windows Terminal, the other on an Ubuntu OS terminal - both to same effect.
>
> This usually happens when the value of TERM environment variable is
>
> incorrect. What do you get if you execute the following command?
>
> typeset -p TERM
>
> In Windows Terminal and GNOME Terminal the correct output is this:
>
> export TERM=xterm-256color
>
> If you are getting any other output, that's the problem.
>
> Roman.


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

end of thread, other threads:[~2021-09-08  9:31 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-09-07 22:58 Bug report: Pasting content overwrites the current line and duplicates the text Christopher Stead
2021-09-07 23:16 ` Bart Schaefer
2021-09-08  8:56 ` Roman Perepelitsa
2021-09-08  9:31   ` Christopher Stead

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).