Re: [PATCH v3 2/3] vimdiff: add tool documentation

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

 



> +                                (diff_mode && diff_cmd_help "$toolname" || merge_cmd_help "$toolname") |

Mis-indenting with spaces v.s. tabs below.

Then this:

> +	diff_cmd_help () {
> +		return 0
> +	}
> +
>  	merge_cmd () {
>  		return 1
>  	}
>  
> +	merge_cmd_help () {
> +		return 0
> +	}
> +
>  	hide_resolved_enabled () {
>  		return 0
>  	}
> diff --git a/mergetools/vimdiff b/mergetools/vimdiff
> index ed0d8584f7..8614253ef1 100644
> --- a/mergetools/vimdiff
> +++ b/mergetools/vimdiff
> @@ -462,6 +462,17 @@ diff_cmd () {
>  }
>  
>  
> +diff_cmd_help() {
> +	case "$1" in
> +	*)
> +		echo "Run 'man git-difftool--vimdiff' for details"
> +		;;
> +	esac
> +
> +	return 0
> +}
> +
> +
>  merge_cmd () {
>  	layout=$(git config mergetool.$merge_tool.layout)
>  
> @@ -533,6 +544,17 @@ merge_cmd () {
>  }
>  
>  
> +merge_cmd_help() {
> +	case "$1" in
> +	*)
> +		echo "Run 'man git-mergetool--vimdiff' for details"
> +		;;
> +	esac
> +
> +	return 0
> +}
> +
> +

Isn't the case/esac in those functions entirely redundant and they could
just "echo"?



[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]

  Powered by Linux