Skip to content
This repository has been archived by the owner on May 7, 2021. It is now read-only.

When I save a file it takes me to the end of the file #322

Closed
mrkaspa opened this issue Dec 5, 2015 · 12 comments
Closed

When I save a file it takes me to the end of the file #322

mrkaspa opened this issue Dec 5, 2015 · 12 comments

Comments

@mrkaspa
Copy link

mrkaspa commented Dec 5, 2015

It's very annoying that every time I save a file it takes the cursor the end of the same so I can't continue in the line that I was coding.

@joefitzgerald
Copy link
Owner

That's not go-plus. What other packages do you have installed? Paste the output of apm list and start disabling other packages until you find the culprit.

@mrkaspa
Copy link
Author

mrkaspa commented Dec 6, 2015

It doesn't happen when I disable the go-plus, so I disabled the format tool and stop happening, is there a special configuration?
screen shot 2015-12-06 at 4 10 44 pm

@joefitzgerald
Copy link
Owner

So you've disabled all other packages that are user-installed? Please paste the output from apm list.

@nwaywood
Copy link

I am having the same issue, it still happens even when I disable every other user installed package apart from go-plus. The issue only happens when saving *.go files.

Here is the output of my apm list

/Users/nick/.atom/packages (25)
├── [email protected]
├── [email protected]
├── [email protected]
├── [email protected]
├── [email protected]
├── [email protected]
├── [email protected]
├── [email protected]
├── [email protected]
├── [email protected]
├── [email protected]
├── [email protected]
├── [email protected]
├── [email protected]
├── [email protected]
├── [email protected]
├── [email protected]
├── [email protected]
├── [email protected]
├── [email protected]
├── [email protected]
├── [email protected]
├── [email protected]
├── [email protected]
└── [email protected]

@mrphilroth
Copy link

This happens for me. It is very annoying.

Output of apm list:

/Users/proth/.atom/packages (16)
├── [email protected]
├── [email protected]
├── [email protected]
├── [email protected]
├── [email protected]
├── [email protected]
├── [email protected]
├── [email protected]
├── [email protected]
├── [email protected]
├── [email protected]
├── [email protected]
├── [email protected]
├── [email protected]
├── [email protected]
└── [email protected]

@joefitzgerald
Copy link
Owner

Are there non-ascii / Unicode characters in the file when you experience this issue?

@mrphilroth
Copy link

Nope. I just reproduced it on a very simple file. It jumps right after the save. The linter messages come up after the jump.

@joefitzgerald
Copy link
Owner

Could you please post a gist with the file contents?

@mrphilroth
Copy link

Here's an example:
https://gist.github.com/mrphilroth/dc82fd67b11d554699d6

I did lots of edits and saves that all made the cursor jump to the end of the file.

There is a reproducible situation where the cursor does not jump the end of the file. I can change the import line to:

import { "log" "doesntExist" }

and save and it jumps. When I manually edit to get the line back to:

import "log"

and save then it does not jump. That's the only non-jump situation I've seen.

@mrphilroth
Copy link

Finally got annoyed at this enough to investigate deeply. After a comparison of our package lists above and some selective installing and uninstalling, I narrowed the culprit down to tabs-to-spaces. Here's the issue: lee-dohm/tabs-to-spaces#41

Sorry to raise the alarm on your excellent package. I think this issue can be closed.

@joefitzgerald
Copy link
Owner

/cc @lee-dohm

@joefitzgerald
Copy link
Owner

Closing as this is an issue with tabs-to-spaces.

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

No branches or pull requests

4 participants