Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

The copied text is not fully pasted #3790

Closed
majonga88 opened this issue Nov 30, 2019 · 4 comments
Closed

The copied text is not fully pasted #3790

majonga88 opened this issue Nov 30, 2019 · 4 comments
Labels
Resolution-Duplicate There's another issue on the tracker that's pretty much the same thing.

Comments

@majonga88
Copy link

Hi folks,

I experienced an issue with copy/paste feature.

Environment

Windows build number: 10.0.18363 N/A Build 18363
Windows Terminal version : 0.7.3291.0

Steps to reproduce

On WSL 1 tab (Ubuntu distro), i create a file touch test.txt in the home path, when edit the file like this : vi test.txt and i would like to copy/paste the following text :

module.exports = {
  async rewrites() {
    return [
      // Basic `path-to-regexp` usage
      // Query object shape: { id: string }
      { source: "/user/:id", destination: "/user_profile" },

      // Optional Language
      // Query object shape: { lang?: string }
      { source: "/:lang(en|es)?/about", destination: "/about" },

      // Advanced rewrite
      // Query object shape: { id: string } (in addition to dynamic route param)
      { source: "/u/:id", destination: "/user/:id" }
    ];
  }
};

Expected behavior

The beginning of the copied text should be not missing.

image

Actual behavior

The beginning of the copied text is missing.

image

Thank you guys for your help !

@ghost ghost added Needs-Triage It's a new issue that the core contributor team needs to triage at the next triage meeting Needs-Tag-Fix Doesn't match tag requirements labels Nov 30, 2019
@DHowett-MSFT
Copy link
Contributor

DHowett-MSFT commented Nov 30, 2019

Since you're using vi, and you are pasting code directly, it looks like m o d u l e . e x p o are being interpreted as vi normal-mode commands. You're issuing the following commands:

  • mo - set mark o
  • du - delete, something
  • l - move right
  • e - move to end of word
  • . - repeat last editing action
  • e - as above
  • x - delete one character (probably the . you just added)
  • p - paste whatever's in your yank buffer (probably labels:) from the first line
  • o - insert a new line below the current line, enter insert mode

Once you're in insert mode, the rest of your paste goes in unharmed.

  1. This is 100% expected behavior for pasting raw text into vim. Press i before pasting to paste code.
  2. Vi/vim support automatic detection of pastes, but requesting that makes this a /dupe of bracketed paste in conhost #395.

@ghost
Copy link

ghost commented Nov 30, 2019

Hi! We've identified this issue as a duplicate of another one that already exists on this Issue Tracker. This specific instance is being closed in favor of tracking the concern over on the referenced thread. Thanks for your report!

@ghost ghost closed this as completed Nov 30, 2019
@ghost ghost added Resolution-Duplicate There's another issue on the tracker that's pretty much the same thing. and removed Needs-Triage It's a new issue that the core contributor team needs to triage at the next triage meeting Needs-Tag-Fix Doesn't match tag requirements labels Nov 30, 2019
@ghost
Copy link

ghost commented Nov 30, 2019

Hi! We've identified this issue as a duplicate of another one that already exists on this Issue Tracker. This specific instance is being closed in favor of tracking the concern over on the referenced thread. Thanks for your report!

@majonga88
Copy link
Author

@DHowett-MSFT Thanks for the answer ! 🍻

This issue was closed.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Resolution-Duplicate There's another issue on the tracker that's pretty much the same thing.
Projects
None yet
Development

No branches or pull requests

2 participants