Re: [PATCH] difftool: print list of valid tools with '--tool-help'

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Tim Henigan <tim.henigan@xxxxxxxxx> writes:

> Rather than create a new entry point, I used the existing
> 'get_merge_tool_path' that resides in 'git-mergetool--lib' to
> determine if a given tool is actually installed on the system.
>
> The '$DISPLAY' variable is lost in this implementation, but honestly I
> don't understand how it was intended to be used.
>
> Does this look useful?

Sounds like a better way to do it.

The point of checking DISPLAY in "cando" is to allow for a tool that
changes its behaviour when launched in terminal-only vs windowed
environment. For example, if somebody tries to spawn a tool that *only*
works in windowed environment (e.g. "kompare") in a terminal-only session,
it would fail, and the "cando" mechanism was designed to allow a tool
detect such a situation and excuse itself from the available tools list.

I think get_merge_tool_path could do the same thing (i.e. report "no
executable available to run this tool" when appropriate), so I do not
think you lost anything.
--
To unsubscribe from this list: send the line "unsubscribe git" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[Index of Archives]     [Linux Kernel Development]     [Gcc Help]     [IETF Annouce]     [DCCP]     [Netdev]     [Networking]     [Security]     [V4L]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux SCSI]     [Fedora Users]