Skip to content

Diff does not work if file does not exist in HEAD #5

@michaeladler

Description

@michaeladler

If I want to review an old commit of a file that no longer exists in HEAD, vim-git-log silently returns and does nothing. My solution was to remove the problematic code part:

if !filereadable(l:repo . '/' . l:filename)
    execute 'cd ' . l:cwd
    return
endif

At the very least you should use echom and warn the user about that behavior, but personally I don't see a reason why that check should exist in the first place.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions