sgeb/vim-diff-fold

Output of diff -r is not folded properly

caetanosauer opened this issue · 0 comments

When looking at the output of "diff -r", which shows the differences between directories recursively, files that only exist in one dir or the other appear like this:

Only in dir1: file1.txt
Only in dir2: file2.txt

To avoid them being hidden under other normal file folds, the following can be added to the function DiffFoldLevel()

 elseif l:line =~# '^Only in' " file only in one folder when using diff -r
    return '>1'