Re: [PATCH 2/2] var doc: advertise current DEFAULT_PAGER and DEFAULT_EDITOR settings

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

 



Jonathan Nieder <jrnieder@xxxxxxxxx> writes:

> Document the default pager and editor chosen at compile time in the
> git-var(1) manpage so users curious about what command _this_ copy of
> git will fall back to when EDITOR, VISUAL, and PAGER are unset can
> find the answer quickly.
>
> In builds leaving those settings uncustomized, this patch makes the
> manpage continue to say "usually vi" and "usually less" so the
> formatted documentation is usable for a wide audience including users
> of custom builds that change those settings.  If you would like your
> copy of the docs to be less noncommittal, you will need to set
> DEFAULT_PAGER=less and DEFAULT_EDITOR=vi explicitly.
>
> Suggested-by: Junio C Hamano <gitster@xxxxxxxxx>
> Signed-off-by: Jonathan Nieder <jrnieder@xxxxxxxxx>
> ---
> Thanks for reading.

Thanks for a patch.

I think the Makefile patch to use "-a" takes the right approach (assuming
that the name of the EDITOR/PAGER won't have funny character that would
trip up AsciiDoc, which I think is a reasonably assumption), but I think
even the customized package should say what it is "usually" set on other
people's systems.

In other words, instead of:

>      `$VISUAL`, then `$EDITOR`, and then the default chosen at compile
> +ifndef::git-default-editor[]
>      time, which is usually 'vi'.
> +endif::git-default-editor[]
> +ifdef::git-default-editor[]
> +    time ('{git-default-editor}').
> +endif::git-default-editor[]

something like:

	... then the default chosen at compile time, which is usually 'vi'.
ifdef::git-default-editor[]
	The build you are using chose '{git-default-editor}' as the default.
endif::git-default-editor[]

may be less confusing.

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