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

magit stages one line too many with evil-visual-line #2476

Closed
mbertheau opened this issue Jul 30, 2015 · 5 comments
Closed

magit stages one line too many with evil-visual-line #2476

mbertheau opened this issue Jul 30, 2015 · 5 comments

Comments

@mbertheau
Copy link
Contributor

In the magit status buffer when I want to stage a single line, if I mark it with V and then hit s to stage, the marked line and the next line get staged. You can see the region extend one line down after hitting s.

Workaround is to mark just one character in the line with v and stage then.

Now v is actually simpler than V, but V makes much more sense for staging a whole line.

@sooheon
Copy link

sooheon commented Jul 30, 2015

I think this may have something to do with the newline character being marked at the end of the line. With V you're selecting the entire line and the newline which begins the next line as well. I guess we can advice the magit state function, but like you said, just using v may be the simpler solution. FWIW, pure emacs users begin marking with C-SPC, and they don't have the linewise marking equivalent, hence the discrepancy.

@mbertheau
Copy link
Contributor Author

There's a similar issue in magit-log, where I select commits with V in order to diff them with d d.

@syl20bnr
Copy link
Owner

I noticed this too and I use the same workaround with v instead of V, it is not really a big deal but it should be mentioned in the documentation.

@jb55
Copy link
Contributor

jb55 commented Jul 31, 2015

This got me as well, I didn't realize you could use v until I read this issue.

TheBB added a commit to TheBB/spacemacs that referenced this issue Sep 30, 2015
@TheBB TheBB mentioned this issue Sep 30, 2015
TheBB added a commit to TheBB/spacemacs that referenced this issue Sep 30, 2015
TheBB added a commit to TheBB/spacemacs that referenced this issue Sep 30, 2015
TheBB added a commit to TheBB/spacemacs that referenced this issue Oct 2, 2015
TheBB added a commit that referenced this issue Oct 5, 2015
@justbur
Copy link
Contributor

justbur commented Oct 28, 2015

Should be fixed with #3578

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

No branches or pull requests

7 participants