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

Some small improvements #3

Open
wants to merge 9 commits into
base: master
Choose a base branch
from
Open

Some small improvements #3

wants to merge 9 commits into from

Conversation

mMontu
Copy link

@mMontu mMontu commented Jan 12, 2015

These are some small improvements on that I made over the years, and finally I took the time to upload them.

I've sent some of them to the original author, but it seems he doesn't use the e-mail at vim.org anymore.

* Always the first difference - the current behavior seems be jumping to the cursor position when the file was last opened for edition. Sometimes some differences are missed because the buffers open with only the last differences on the screen.

* Move the cursor to the first difference - the current behavior seems to be leaving the cursor at the diff window. I've found that most of the time it is necessary to check the changes on many files, and using \dj and \dk leaves the cursor on diff window, so it is necessary to move back to the diff windows.
The current behavior uses `:bd` to close a diff window after it is displayed on
the screen, which causes any other windows displaying that file to be closed.

The option g:DirDiffBufferDelete allows to use `:q` instead. In this case the
`:diffoff` is also necessary to avoid subsequent diffs to be displayed
incorrectly.
@@ -308,6 +308,10 @@ endif
if !exists("g:DirDiffTextOnlyInCenter")
let g:DirDiffTextOnlyInCenter = ": "
endif
" Selects if a buffer is deleted after it is displayed in a diff

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

"If true, the buffer is deleted after being displayed in a diff"

@mMontu
Copy link
Author

mMontu commented Jan 13, 2015

I've added one commit yesterday, but I'm not sure if github generates a message about it.

@mMontu
Copy link
Author

mMontu commented Jan 20, 2015

I didn't understand the use of s:DirDiffIsRunning, introduced by 363cd0f, but it is clearly buggy, as it makes impossible to update ('u') the diff list after changing the exclude pattern ('x').

It is unclear why the user should be prevented from using more than one DirDiff, as it works fine when you have each one on its own tabpage.

@justinmk
Copy link

Yeah I don't understand it either

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