sindrets / diffview.nvim

Single tabpage interface for easily cycling through diffs for all modified files for any git rev.
Other
3.85k stars 105 forks source link

`:checkhealth` says "ERROR: Configured hg_cmd is not executable: 'hg'" #319

Closed erikw closed 1 year ago

erikw commented 1 year ago

When running :checkhealth it is reported under the ## Checking external dependencies section:

ERROR: Configured hg_cmd is not executable: 'hg'

This is correct as my system does not have hg installed. However hg is not listed as a requirement for this plugin, so I think this check should not be included by default.

I've been trying to work around this by unsetting the hg_cmd in the config like:

None of these worked as a workaround. Either way, as hg is not a requirement, I think it should not fail on :checkhealth either.

sindrets commented 1 year ago

I demoted the missing VCS tool exception to a warning. It will now error only if no valid VCS tool is found. I'm gonna try to update the "dependencies" section in the README soon. Mercurial support is a relatively new addition, and hg is only required if you want to use the plugin with Mercurial repos.

erikw commented 1 year ago

Thank you, I can confirm it's a warning now after updating.

NeilGirdhar commented 1 year ago

Would be cool to make this completely silenceable 😄

sindrets commented 1 year ago

What would be the point? The warning is there to say that something might require the user's attention.

NeilGirdhar commented 1 year ago

Yeah, and I can suppress similar warnings from provider by setting:

    vim.g.loaded_node_provider = 0
    vim.g.loaded_perl_provider = 0
    vim.g.loaded_ruby_provider = 0

The benefit would be that as you scan down the check-health output, you don't see anything red that you have to ask yourself if it's actually important.

But I agree that this is minor, and while I'm here thank you very much for your awesome plugin 😄