Re: [PATCH/RFC] Add support for the google-chrome web browser

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

 



Evan Farrer <evan.farrer@xxxxxxxxx> writes:

> Signed-off-by: Evan Farrer <Evan.Farrer@xxxxxxxxx>
> ---
>  Documentation/git-web--browse.txt |    1 +
>  git-web--browse.sh                |    6 +++---
>  2 files changed, 4 insertions(+), 3 deletions(-)
>
> diff --git a/Documentation/git-web--browse.txt b/Documentation/git-web--browse.txt
> index 278cf73..0994139 100644
> --- a/Documentation/git-web--browse.txt
> +++ b/Documentation/git-web--browse.txt
> @@ -25,6 +25,7 @@ The following browsers (or commands) are currently supported:
>  * links
>  * lynx
>  * dillo
> +* google-chrome

Hmmm, the support added by this patch for the chrome is, together with
w3m, links, and open, to simply run the command with given arguments
without any other magic.

Perhaps valid_custom_tool() function should be changed to simply return $1
if $browser_cmd is not found, like this:

	valid_custom_tool ()
        {
        	browser_cmd=$(git config "browser.$1.cmd")
                : ${browser_cmdn:=$1}
	}

Then we don't even have to add any specific support for "google-chrome" or
anything that takes "$command $path..." and opens the documents.

Is there a downside in this approach?
--
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]