Re: [PATCH 1/3] fixup! mergetool--lib: add functions for finding available tools

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

 



On Wed, Jan 30, 2013 at 12:23:34PM -0800, Junio C Hamano wrote:
> > diff --git a/git-mergetool--lib.sh b/git-mergetool--lib.sh
> > index 25631cd..b6ed2fa 100644
> > --- a/git-mergetool--lib.sh
> > +++ b/git-mergetool--lib.sh
> > @@ -34,9 +34,9 @@ show_tool_names () {
> >  				then
> >  					echo "$preamble"
> >  					preamble=
> > -					shown_any=yes
> >  				fi
> > -				printf "%s%s\n" "$per_line_prefix" "$tool"
> > +				shown_any=yes
> > +				printf "%s%s\n" "$per_line_prefix" "$toolname"
> 
> Thanks for spotting s/tool/toolname/; does the change to shown_any
> matter, though?

Not really since we don't call it with an empty "$preamble" but if
something ever did then this ensures that shown_any is set correctly.

The $tool -> $toolname doesn't really matter either since setup_tool
sets it as a global variable, but I'd rather not rely on that.

> >  			fi
> >  		done
> >  		test -n "$shown_any"
> > @@ -244,6 +244,7 @@ show_tool_help () {
> >  
> >  	tab='	' av_shown= unav_shown=
> >  
> > +	cmd_name=${TOOL_MODE}tool
> >  	if show_tool_names 'mode_ok && is_available' "$tab$tab" \
> >  		"$tool_opt may be set to one of the following:"
> >  	then
--
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]