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

replacing characters via r in .go files does not work in unsaved files #1139

Open
8 tasks done
xh3b4sd opened this issue Apr 5, 2020 · 4 comments
Open
8 tasks done

Comments

@xh3b4sd
Copy link

xh3b4sd commented Apr 5, 2020

debug info
{
  "atom": "1.45.0",
  "platform": "darwin",
  "release": "19.4.0",
  "vmpVersion": "1.36.4",
  "vmpConfig": {
    "useClipboardAsDefaultRegister": false
  }
}

Relevant packages I use:

Checklist

You have to check all before open issue.

  • Provide your environment info clipped by Vim Mode Plus: Clip Debug Info command.
  • Try with latest Atom and latest vim-mode-plus.
  • Pick a descriptive and non-ambiguous subject
  • Express "what" you want(feature? config option?, behavior change?) in short sentence(not long!).
  • Contrast current behavior if you want to change current behavior, with sample text, operation(keystroke) and result.
  • Include real use case so that maintainer can understand "why" you need help.
  • Include Atom(atom --version), vim-mode-plus version, and OS version(e.g. macOS Sierra 10.12.3).
  • If keybinding issue, Read this.

what I want

reporting a bug

current vs desired behaviour

I have a simple go file, go-plus and autosave enabled. Cursor above x in the comment.

package x

// x

Hitting r and then e replaces x with e. The file changed. Again hitting r and then x does not replace e with x, but it should. When I disable either of go-plus or autosave packages the second attempt of replacing e with x works as expected.

use case

I replace a lot of characters every day and run a lot into the issue for quite some time now. I finally made the effort to report the bug.

more thoughts

I checked the key bindings and they do not seem to be the issue. I tried to debug the JS code but this is not my expertise at all so I couldn't really figure anything. I would maybe be interested in learning a bit more so I can be more helpful here since I rely heavily on vim-mode-plus. I like it a lot.

@t9md
Copy link
Owner

t9md commented Apr 7, 2020

Thank you for the kind comment. Btw, Have you reported this issue to go-plus?
I tried with autosave enabled, but I couldn't reproduce. So I think go-plus is somewhat related to this issue.
Plus your debug info is super short, did you pasted the clipboard result which you captured "Vim Mode Plus: Clip Debug Info" command ?

@xh3b4sd
Copy link
Author

xh3b4sd commented Apr 7, 2020

I did not report it further, but I can raise it with go-plus. I checked the debug info again and it copies the same. I do not get more out of it.

@t9md
Copy link
Owner

t9md commented Apr 7, 2020

OK, for the Clip Debug Info command, you are right. The length of output just depends on what amount of configuration you have changed from the default.

@xh3b4sd xh3b4sd changed the title replaceing characters via r in .go files does not in unsaved files replacing characters via r in .go files does not in unsaved files Apr 7, 2020
@xh3b4sd xh3b4sd changed the title replacing characters via r in .go files does not in unsaved files replacing characters via r in .go files does not work in unsaved files Apr 7, 2020
@xh3b4sd
Copy link
Author

xh3b4sd commented Apr 7, 2020

Created the other issue. See joefitzgerald/go-plus#1012.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants