On Wed, Oct 24, 2018 at 02:10:14PM +0900, Junio C Hamano wrote: > In mode_ok shell function, we seem to be prepared to deal with a > case where neither diff_mode nor merge_mode is true. Should this > codepath also be prepared to? > According to Documentation/git-mergetool--lib.txt, >Before sourcing 'git-mergetool{litdd}lib', your script must set `TOOL_MODE` >to define the operation mode for the functions listed below. >'diff' and 'merge' are valid values. so I think that we can assume that the one of diff_mode or merge_mode will return true. In any case, it seems like the rest of the code was written under this assumption so if this needs to be changed then the whole library needs to be fixed as well.