{"thread":{"id":"30105","subject":"Re: [PATCH] Documentation: replace 'vi' for 'editor' to reflect build-time option","startedAt":"2012-03-30T00:55:23Z","lastAt":"2012-04-18T20:02:15Z","messageCount":11,"participants":["Jonathan Nieder","Junio C Hamano","Rodrigo Silva","Phil Hord"],"isPatch":true,"patchVersion":1,"patchTotal":null},"messages":[{"id":"188110","messageId":"20120330005523.GA28519@burratino","threadId":"30105","inReplyTo":"20120330002543.2138.91961.reportbug@localhost6.localdomain6","subject":"Re: [PATCH] Documentation: replace 'vi' for 'editor' to reflect build-time option","fromName":"Jonathan Nieder","fromEmail":"jrnieder@gmail.com","sentAt":"2012-03-30T00:55:23Z","receivedAt":"2012-03-30T00:55:23Z","isPatch":true,"sender":{"key":"jrnieder@gmail.com","avatar":"https://avatars.githubusercontent.com/u/281595?v=4"},"body":"Hi Rodrigo,\n\nRodrigo Silva (MestreLion) wrote:\n\n> git-var(1) did not say that hardcoded fallback 'vi' may have been changed\n> at build time. A user could be puzzled if 'nano' pops up even when none of the\n> mentioned environment vars or config.editor are set.\n>\n> Ideally, the build system should be changed to reflect the chosen fallback\n> editor when creating the man pages. Not sure if that is even possible though.\n\nGood catch.\n\nFilling in the blank at compile time would be possible, but I'm not\nconvinced it's a good idea.  Wouldn't the same user be just as puzzled\nwhen\n\n  http://git.kernel.org/?p=git/git-htmldocs.git;a=blob_plain;f=git-var.html\n\n(or whatever page with a nicer URL arises to replace the old\nwww.kernel.org/...  pages) says the fallback is 'vi' and git behaves\ndifferently?\n\nHow about something like this?\n\nSigned-off-by: Jonathan Nieder <jrnieder@gmail.com>\n---\nContext: http://bugs.debian.org/666250\n\n Documentation/git-var.txt |    6 ++++--\n 1 file changed, 4 insertions(+), 2 deletions(-)\n\ndiff --git i/Documentation/git-var.txt w/Documentation/git-var.txt\nindex 5317cc24..beef9e28 100644\n--- i/Documentation/git-var.txt\n+++ w/Documentation/git-var.txt\n@@ -43,13 +43,15 @@ GIT_EDITOR::\n     `$SOME_ENVIRONMENT_VARIABLE`, `\"C:\\Program Files\\Vim\\gvim.exe\"\n     --nofork`.  The order of preference is the `$GIT_EDITOR`\n     environment variable, then `core.editor` configuration, then\n-    `$VISUAL`, then `$EDITOR`, and then finally 'vi'.\n+    `$VISUAL`, then `$EDITOR`, and then the default chosen at compile\n+    time, which is usually 'vi'.\n \n GIT_PAGER::\n     Text viewer for use by git commands (e.g., 'less').  The value\n     is meant to be interpreted by the shell.  The order of preference\n     is the `$GIT_PAGER` environment variable, then `core.pager`\n-    configuration, then `$PAGER`, and then finally 'less'.\n+    configuration, then `$PAGER`, and then the default chosen at\n+    compile time (usually 'less').\n \n Diagnostics\n -----------\n-- \n"},{"id":"188116","messageId":"7v398qq1ei.fsf@alter.siamese.dyndns.org","threadId":"30105","inReplyTo":"20120330005523.GA28519@burratino","subject":"Re: [PATCH] Documentation: replace 'vi' for 'editor' to reflect build-time option","fromName":"Junio C Hamano","fromEmail":"gitster@pobox.com","sentAt":"2012-03-30T02:16:05Z","receivedAt":"2012-03-30T02:16:05Z","isPatch":true,"sender":{"key":"gitster@pobox.com","avatar":"https://avatars.githubusercontent.com/u/54884?v=4"},"body":"Jonathan Nieder <jrnieder@gmail.com> writes:\n\n> Filling in the blank at compile time would be possible, but I'm not\n> convinced it's a good idea.  Wouldn't the same user be just as puzzled\n> when\n>\n>   http://git.kernel.org/?p=git/git-htmldocs.git;a=blob_plain;f=git-var.html\n>\n> (or whatever page with a nicer URL arises to replace the old\n> www.kernel.org/...  pages) says the fallback is 'vi' and git behaves\n> differently?\n\nI've already rejected this patch once, but that was primarily because the\npatch was not justified with the above \"I read everybody else's git uses\n'vi' on the Interweb, and even though my distro's manual page says it uses\n'nano', I didn't bother to read it.\" scenario.\n"},{"id":"188144","messageId":"BuLHbqo4rrB.A.lMC.A5YdPB@liszt","threadId":"30105","inReplyTo":"7v398qq1ei.fsf@alter.siamese.dyndns.org","subject":"Bug#666250: [PATCH] Documentation: replace 'vi' for 'editor' to reflect build-time option","fromName":"Rodrigo Silva","fromEmail":"linux@rodrigosilva.com","sentAt":"2012-03-30T10:33:21Z","receivedAt":"2012-03-30T10:33:21Z","isPatch":true,"sender":{"key":"linux@rodrigosilva.com","avatar":"https://avatars.githubusercontent.com/u/992317?v=4"},"body":"At 23:16 29/3/2012, Junio C Hamano wrote:\n>Jonathan Nieder <jrnieder@gmail.com> writes:\n>\n>> Filling in the blank at compile time would be possible, but I'm not\n>> convinced it's a good idea.  Wouldn't the same user be just as puzzled\n>> when\n>>\n>>   http://git.kernel.org/?p=git/git-htmldocs.git;a=blob_plain;f=git-var.html\n>>\n>> (or whatever page with a nicer URL arises to replace the old\n>> www.kernel.org/...  pages) says the fallback is 'vi' and git behaves\n>> differently?\n>\n>I've already rejected this patch once, but that was primarily because the\n>patch was not justified with the above \"I read everybody else's git uses\n>'vi' on the Interweb, and even though my distro's manual page says it uses\n>'nano', I didn't bother to read it.\" scenario.\n\n@Jonathan: I'm really sorry for this confusion... I forgot to mention this issue WAS taken to upstream already, and it was rejected because build-time options should be documented by whoever did the changes. So in this case, it's Debian's task to update their man pags to reflect their build-time changes. Junio suggested me to send this patch to Debian, that's why I filled the bug in Debian BTS. It was meant to be a Debian-only patch.\n\nSo upstream git man would still say \"... and finally 'vi'\", since this is upstream default, and Debian would read \"... and finally 'editor'\", since this is the default set by Debian at build-time. For reference, the original patch included this change, among others:\n\ndiff --git a/Documentation/git-var.txt b/Documentation/git-var.txt\nindex 5317cc2..9c49163 100644\n--- a/Documentation/git-var.txt\n+++ b/Documentation/git-var.txt\n@@ -43,7 +43,8 @@ GIT_EDITOR::\n     `$SOME_ENVIRONMENT_VARIABLE`, `\"C:\\Program Files\\Vim\\gvim.exe\"\n     --nofork`.  The order of preference is the `$GIT_EDITOR`\n     environment variable, then `core.editor` configuration, then\n-    `$VISUAL`, then `$EDITOR`, and then finally 'vi'.\n+    `$VISUAL`, then `$EDITOR`, and then finally a hardcoded fallback\n+    editor set at build time, by default 'vi'.\n \n GIT_PAGER::\n     Text viewer for use by git commands (e.g., 'less').  The value\n\nThe other changes were fully accepted upstream, this one was rejected. So I modified it to Debian's scenario and filled the bug in BTS.\n\nSince this is meant for Debian, no need to be generic about the \"fallback editor set at build time\": Debian uses 'editor', so 'editor' should be explicitly mentioned to correctly reflect git's behavior on a Debian system.\n\n@Junio, I'm really sorry for indirectly bringing this up twice to your attention. I've never expected Debian maitainers to be so resposinve, it was awesome fast by reading, analysing and forwarding upstream in a matter of hours. I'm impressed (and embarasssed by this confusion)\n\nMestreLion\n"},{"id":"188179","messageId":"7viphmm3yd.fsf@alter.siamese.dyndns.org","threadId":"30105","inReplyTo":"20120330103326.272B040A067@cobalt.pobox.com","subject":"Re: [PATCH] Documentation: replace 'vi' for 'editor' to reflect build-time option","fromName":"Junio C Hamano","fromEmail":"gitster@pobox.com","sentAt":"2012-03-30T16:46:50Z","receivedAt":"2012-03-30T16:46:50Z","isPatch":true,"sender":{"key":"gitster@pobox.com","avatar":"https://avatars.githubusercontent.com/u/54884?v=4"},"body":"Rodrigo Silva <linux@rodrigosilva.com> writes:\n\n> At 23:16 29/3/2012, Junio C Hamano wrote:\n> ...\n>>I've already rejected this patch once, but that was primarily because the\n>>patch was not justified with the above \"I read everybody else's git uses\n>>'vi' on the Interweb, and even though my distro's manual page says it uses\n>>'nano', I didn't bother to read it.\" scenario.\n>\n> @Jonathan: I'm really sorry for this confusion...\n> ... Junio suggested me to send this patch to\n> Debian, that's why I filled the bug in Debian BTS. It was meant to be a\n> Debian-only patch.\n\nIt is a Debian package bug that the git_*.diff patch they use to customize\nthe upstream source ends up making a resulting binary to use different\neditor and pager but does so without editing Documentation/ files to match\nthe description to what their executable does.  The resulting package is\nnot self consistent.\n\nBut we aren't making it particularly easy for Debian to do so.\n\nThe debian/rules (the Makefile that invokes our Makefile) file in the\ngit_*.diff patch merely overrides DEFAULT_EDITOR and DEFAULT_PAGER,\ninstead of patching editor.c and pager.c to replace the fallback hardcoded\ndefaults \"vi\" and \"less\".  But these Makefile variables only affect that\ngoes in the executable, and they do not affect the documentation.\n\nSo in the shorter term, I think Jonathan's patch would be OK for me to\ncarry in my tree, but even in that case I think Debian still needs to\nreplace the \"vi/less\" in the documentation to tell what they chosen for\ntheir users.\n\nIn the longer term, it may make more sense to let these Makefile variables\nreplace \"vi\" and \"less\" with whatever values set to them, while keeping\nthe \"default chosen at the build time, usually\" wording.\n\nIn any case, I'd appreciate it if either of you can turn Jonathan's \"How\nabout something like this?\" into the final version to be fed to \"git am\".\n\nThanks.\n"},{"id":"188237","messageId":"20120331084015.GC4119@burratino","threadId":"30105","inReplyTo":"7v398qq1ei.fsf@alter.siamese.dyndns.org","subject":"[PATCH 0/2] Re: Documentation: replace 'vi' for 'editor' to reflect build-time option","fromName":"Jonathan Nieder","fromEmail":"jrnieder@gmail.com","sentAt":"2012-03-31T08:40:15Z","receivedAt":"2012-03-31T08:40:15Z","isPatch":true,"sender":{"key":"jrnieder@gmail.com","avatar":"https://avatars.githubusercontent.com/u/281595?v=4"},"body":"Junio C Hamano wrote:\n\n> I've already rejected this patch once, but that was primarily because the\n> patch was not justified with the above \"I read everybody else's git uses\n> 'vi' on the Interweb, and even though my distro's manual page says it uses\n> 'nano', I didn't bother to read it.\" scenario.\n\nThanks.  Here's a pair of patches meant to combine the advantages of\nboth approaches. ;-)\n\nThoughts and improvements welcome, of course.\n\nSincerely,\nJonathan Nieder (2):\n  var doc: default editor and pager are configurable at build time\n  var doc: advertise current DEFAULT_PAGER and DEFAULT_EDITOR settings\n\n Documentation/Makefile    |   10 ++++++++++\n Documentation/git-var.txt |   16 ++++++++++++++--\n Makefile                  |    2 ++\n 3 files changed, 26 insertions(+), 2 deletions(-)\n"},{"id":"188238","messageId":"20120331084234.GD4119@burratino","threadId":"30105","inReplyTo":"20120331084015.GC4119@burratino","subject":"[PATCH 1/2] var doc: default editor and pager are configurable at build time","fromName":"Jonathan Nieder","fromEmail":"jrnieder@gmail.com","sentAt":"2012-03-31T08:42:34Z","receivedAt":"2012-03-31T08:42:34Z","isPatch":true,"sender":{"key":"jrnieder@gmail.com","avatar":"https://avatars.githubusercontent.com/u/281595?v=4"},"body":"Some distributors customize the fallback pager and editor used by git\ncommands when the user has not indicated a preference via the\ncore.editor/core.pager configuration or GIT_EDITOR, GIT_PAGER, VISUAL,\nEDITOR, and PAGER environment variables, and git's build system\nprovides DEFAULT_PAGER and DEFAULT_EDITOR makefile settings to help\nthem with that (see v1.6.6-rc0~24, 2009-11-20).\n\nUnfortunately those compile-time settings do not affect the\ndocumentation, so the uninitiated user who tries to understand git by\nreading the git-var(1) manpage can easily be confused when git falls\nback to 'nano' and 'more' instead of 'vi' and 'less'.  Even if the\ndistributor patches the distributed docs to reflect the new default,\nthe user may read the official documentation from the git-htmldocs\nrepository online and be confused in the same way.\n\nAdd a few words stating that the defaults are customizable at\ncompile time to make the behavior crystal clear.\n\nReported-by: Rodrigo Silva (MestreLion) <linux@rodrigosilva.com>\nSigned-off-by: Jonathan Nieder <jrnieder@gmail.com>\n---\n Documentation/git-var.txt |    6 ++++--\n 1 file changed, 4 insertions(+), 2 deletions(-)\n\ndiff --git a/Documentation/git-var.txt b/Documentation/git-var.txt\nindex 5317cc24..beef9e28 100644\n--- a/Documentation/git-var.txt\n+++ b/Documentation/git-var.txt\n@@ -43,13 +43,15 @@ GIT_EDITOR::\n     `$SOME_ENVIRONMENT_VARIABLE`, `\"C:\\Program Files\\Vim\\gvim.exe\"\n     --nofork`.  The order of preference is the `$GIT_EDITOR`\n     environment variable, then `core.editor` configuration, then\n-    `$VISUAL`, then `$EDITOR`, and then finally 'vi'.\n+    `$VISUAL`, then `$EDITOR`, and then the default chosen at compile\n+    time, which is usually 'vi'.\n \n GIT_PAGER::\n     Text viewer for use by git commands (e.g., 'less').  The value\n     is meant to be interpreted by the shell.  The order of preference\n     is the `$GIT_PAGER` environment variable, then `core.pager`\n-    configuration, then `$PAGER`, and then finally 'less'.\n+    configuration, then `$PAGER`, and then the default chosen at\n+    compile time (usually 'less').\n \n Diagnostics\n -----------\n-- \n1.7.10.rc3\n"},{"id":"188239","messageId":"20120331084453.GE4119@burratino","threadId":"30105","inReplyTo":"20120331084015.GC4119@burratino","subject":"[PATCH 2/2] var doc: advertise current DEFAULT_PAGER and DEFAULT_EDITOR settings","fromName":"Jonathan Nieder","fromEmail":"jrnieder@gmail.com","sentAt":"2012-03-31T08:44:53Z","receivedAt":"2012-03-31T08:44:53Z","isPatch":true,"sender":{"key":"jrnieder@gmail.com","avatar":"https://avatars.githubusercontent.com/u/281595?v=4"},"body":"Document the default pager and editor chosen at compile time in the\ngit-var(1) manpage so users curious about what command _this_ copy of\ngit will fall back to when EDITOR, VISUAL, and PAGER are unset can\nfind the answer quickly.\n\nIn builds leaving those settings uncustomized, this patch makes the\nmanpage continue to say \"usually vi\" and \"usually less\" so the\nformatted documentation is usable for a wide audience including users\nof custom builds that change those settings.  If you would like your\ncopy of the docs to be less noncommittal, you will need to set\nDEFAULT_PAGER=less and DEFAULT_EDITOR=vi explicitly.\n\nSuggested-by: Junio C Hamano <gitster@pobox.com>\nSigned-off-by: Jonathan Nieder <jrnieder@gmail.com>\n---\nThanks for reading.\n\n Documentation/Makefile    |   10 ++++++++++\n Documentation/git-var.txt |   10 ++++++++++\n Makefile                  |    2 ++\n 3 files changed, 22 insertions(+)\n\ndiff --git a/Documentation/Makefile b/Documentation/Makefile\nindex d40e211f..9fee0b92 100644\n--- a/Documentation/Makefile\n+++ b/Documentation/Makefile\n@@ -124,6 +124,16 @@ SHELL_PATH ?= $(SHELL)\n # Shell quote;\n SHELL_PATH_SQ = $(subst ','\\'',$(SHELL_PATH))\n \n+ifdef DEFAULT_PAGER\n+DEFAULT_PAGER_SQ = $(subst ','\\'',$(DEFAULT_PAGER))\n+ASCIIDOC_EXTRA += -a 'git-default-pager=$(DEFAULT_PAGER_SQ)'\n+endif\n+\n+ifdef DEFAULT_EDITOR\n+DEFAULT_EDITOR_SQ = $(subst ','\\'',$(DEFAULT_EDITOR))\n+ASCIIDOC_EXTRA += -a 'git-default-editor=$(DEFAULT_EDITOR_SQ)'\n+endif\n+\n #\n # Please note that there is a minor bug in asciidoc.\n # The version after 6.0.3 _will_ include the patch found here:\ndiff --git a/Documentation/git-var.txt b/Documentation/git-var.txt\nindex beef9e28..44a5e356 100644\n--- a/Documentation/git-var.txt\n+++ b/Documentation/git-var.txt\n@@ -44,14 +44,24 @@ GIT_EDITOR::\n     --nofork`.  The order of preference is the `$GIT_EDITOR`\n     environment variable, then `core.editor` configuration, then\n     `$VISUAL`, then `$EDITOR`, and then the default chosen at compile\n+ifndef::git-default-editor[]\n     time, which is usually 'vi'.\n+endif::git-default-editor[]\n+ifdef::git-default-editor[]\n+    time ('{git-default-editor}').\n+endif::git-default-editor[]\n \n GIT_PAGER::\n     Text viewer for use by git commands (e.g., 'less').  The value\n     is meant to be interpreted by the shell.  The order of preference\n     is the `$GIT_PAGER` environment variable, then `core.pager`\n     configuration, then `$PAGER`, and then the default chosen at\n+ifndef::git-default-pager[]\n     compile time (usually 'less').\n+endif::git-default-pager[]\n+ifdef::git-default-pager[]\n+    compile time ('{git-default-pager}').\n+endif::git-default-pager[]\n \n Diagnostics\n -----------\ndiff --git a/Makefile b/Makefile\nindex be1957a5..adc48b0d 100644\n--- a/Makefile\n+++ b/Makefile\n@@ -2258,6 +2258,8 @@ $(XDIFF_LIB): $(XDIFF_OBJS)\n $(VCSSVN_LIB): $(VCSSVN_OBJS)\n \t$(QUIET_AR)$(RM) $@ && $(AR) rcs $@ $(VCSSVN_OBJS)\n \n+export DEFAULT_EDITOR DEFAULT_PAGER\n+\n doc:\n \t$(MAKE) -C Documentation all\n \n-- \n1.7.10.rc3\n"},{"id":"188246","messageId":"20120331105106.GA12552@burratino","threadId":"30105","inReplyTo":"4f76de0e.2ac7b60a.54ce.ffffd85eSMTPIN_ADDED@mx.google.com","subject":"Re: [PATCH 1/2] var doc: default editor and pager are configurable at build time","fromName":"Jonathan Nieder","fromEmail":"jrnieder@gmail.com","sentAt":"2012-03-31T10:51:06Z","receivedAt":"2012-03-31T10:51:06Z","isPatch":true,"sender":{"key":"jrnieder@gmail.com","avatar":"https://avatars.githubusercontent.com/u/281595?v=4"},"body":"Hi Rodrigo,\n\nRodrigo Silva wrote:\n \n>> Unfortunately those compile-time settings do not affect the\n>> documentation, so the uninitiated user who tries to understand git by\n>> reading the git-var(1) manpage can easily be confused when git falls\n>> back to 'nano' and 'more' instead of 'vi' and 'less'.  Even if the\n>> distributor patches the distributed docs to reflect the new default,\n>> the user may read the official documentation from the git-htmldocs\n>> repository online and be confused in the same way.\n>\n> I'm sorry, but I disagree with this approach. There is no \"usually\":\n> upstream sources are *always* 'vi', and Debian packages are *always*\n> 'editor'.\n\nI disagree.  If I build the pristine source from Junio with\n\"./configure --with-shell=my-favorite-shell\", I still have built the\npristine source from Junio.\n\n[...]\n> Upstream git /could/ say \"... and finally, a hardcoded editor chosen\n> at compile time, by default 'vi'\"\n\nIt is not hardcoded.\n\n[...]\n> IMHO, only saying that \"it can be customized\", \"it is usually 'vi'\",\n> without saying it /was/ customized and it /isn't/ vi, but editor, is\n> not a good approach.\n\nAh, perhaps that is the source of misunderstanding.  This is a\ntwo-patch series.  The two patches are meant to go together.  Does\nthat help?\n\nSorry for the lack of clarity,\nJonathan\n"},{"id":"188257","messageId":"7v1uo8k64l.fsf@alter.siamese.dyndns.org","threadId":"30105","inReplyTo":"20120331084453.GE4119@burratino","subject":"Re: [PATCH 2/2] var doc: advertise current DEFAULT_PAGER and DEFAULT_EDITOR settings","fromName":"Junio C Hamano","fromEmail":"gitster@pobox.com","sentAt":"2012-03-31T17:55:06Z","receivedAt":"2012-03-31T17:55:06Z","isPatch":true,"sender":{"key":"gitster@pobox.com","avatar":"https://avatars.githubusercontent.com/u/54884?v=4"},"body":"Jonathan Nieder <jrnieder@gmail.com> writes:\n\n> Document the default pager and editor chosen at compile time in the\n> git-var(1) manpage so users curious about what command _this_ copy of\n> git will fall back to when EDITOR, VISUAL, and PAGER are unset can\n> find the answer quickly.\n>\n> In builds leaving those settings uncustomized, this patch makes the\n> manpage continue to say \"usually vi\" and \"usually less\" so the\n> formatted documentation is usable for a wide audience including users\n> of custom builds that change those settings.  If you would like your\n> copy of the docs to be less noncommittal, you will need to set\n> DEFAULT_PAGER=less and DEFAULT_EDITOR=vi explicitly.\n>\n> Suggested-by: Junio C Hamano <gitster@pobox.com>\n> Signed-off-by: Jonathan Nieder <jrnieder@gmail.com>\n> ---\n> Thanks for reading.\n\nThanks for a patch.\n\nI think the Makefile patch to use \"-a\" takes the right approach (assuming\nthat the name of the EDITOR/PAGER won't have funny character that would\ntrip up AsciiDoc, which I think is a reasonably assumption), but I think\neven the customized package should say what it is \"usually\" set on other\npeople's systems.\n\nIn other words, instead of:\n\n>      `$VISUAL`, then `$EDITOR`, and then the default chosen at compile\n> +ifndef::git-default-editor[]\n>      time, which is usually 'vi'.\n> +endif::git-default-editor[]\n> +ifdef::git-default-editor[]\n> +    time ('{git-default-editor}').\n> +endif::git-default-editor[]\n\nsomething like:\n\n\t... then the default chosen at compile time, which is usually 'vi'.\nifdef::git-default-editor[]\n\tThe build you are using chose '{git-default-editor}' as the default.\nendif::git-default-editor[]\n\nmay be less confusing.\n"},{"id":"188263","messageId":"CABURp0o06PsOWznpDh+c_YngLf74jO-qJeqmmwqRyqcU92HyYg@mail.gmail.com","threadId":"30105","inReplyTo":"7v398qq1ei.fsf@alter.siamese.dyndns.org","subject":"Re: [PATCH] Documentation: replace 'vi' for 'editor' to reflect build-time option","fromName":"Phil Hord","fromEmail":"phil.hord@gmail.com","sentAt":"2012-03-31T20:29:47Z","receivedAt":"2012-03-31T20:29:47Z","isPatch":true,"sender":{"key":"phil.hord@gmail.com","avatar":"https://avatars.githubusercontent.com/u/123908?v=4"},"body":"On Thu, Mar 29, 2012 at 10:16 PM, Junio C Hamano <gitster@pobox.com> wrote:\n> Jonathan Nieder <jrnieder@gmail.com> writes:\n>\n>> Filling in the blank at compile time would be possible, but I'm not\n>> convinced it's a good idea.  Wouldn't the same user be just as puzzled\n>> when\n>>\n>>   http://git.kernel.org/?p=git/git-htmldocs.git;a=blob_plain;f=git-var.html\n>>\n>> (or whatever page with a nicer URL arises to replace the old\n>> www.kernel.org/...  pages) says the fallback is 'vi' and git behaves\n>> differently?\n>\n> I've already rejected this patch once, but that was primarily because the\n> patch was not justified with the above \"I read everybody else's git uses\n> 'vi' on the Interweb, and even though my distro's manual page says it uses\n> 'nano', I didn't bother to read it.\" scenario.\n\nI like this original patch, and I like being able to refer to \"the\"\nonline docs wherever I and google may happen to find them.\n\nBecause \"my distro\" may be a resource-constrained minimal OS which\nomitted the git manual.  The same system for similar reasons may\ndefault to 'nano' & 'more' if vi and less are unavailable.\n\nPhil\n"},{"id":"189652","messageId":"20120418200215.GB30558@burratino","threadId":"30105","inReplyTo":"7v1uo8k64l.fsf@alter.siamese.dyndns.org","subject":"Re: [PATCH 2/2] var doc: advertise current DEFAULT_PAGER and DEFAULT_EDITOR settings","fromName":"Jonathan Nieder","fromEmail":"jrnieder@gmail.com","sentAt":"2012-04-18T20:02:15Z","receivedAt":"2012-04-18T20:02:15Z","isPatch":true,"sender":{"key":"jrnieder@gmail.com","avatar":"https://avatars.githubusercontent.com/u/281595?v=4"},"body":"Hi Junio,\n\nJunio C Hamano wrote:\n\n> something like:\n>\n> \t... then the default chosen at compile time, which is usually 'vi'.\n> ifdef::git-default-editor[]\n> \tThe build you are using chose '{git-default-editor}' as the default.\n> endif::git-default-editor[]\n>\n> may be less confusing.\n\nI was not sure if this text would interrupt the flow of reading\nbefore, but I couldn't think of a good alternative so I didn't say\nanything.  Sorry about that.  Now I've looked at the built result and\nthink the new text is good. :)\n\nThanks,\nJonathan\n"}]}