From: Felipe Contreras <felipe.contreras@gmail.com>
To: Junio C Hamano <gitster@pobox.com>
Cc: git@vger.kernel.org
Subject: Re: [PATCH 6/7] user-manual: add global config section
Date: Fri, 1 May 2009 11:37:37 +0300 [thread overview]
Message-ID: <94a0d4530905010137h772b53f1q8af0d30400a05043@mail.gmail.com> (raw)
In-Reply-To: <7v7i1zv3cg.fsf@gitster.siamese.dyndns.org>
On Sun, Apr 5, 2009 at 12:47 PM, Junio C Hamano <gitster@pobox.com> wrote:
> Felipe Contreras <felipe.contreras@gmail.com> writes:
>
>> Signed-off-by: Felipe Contreras <felipe.contreras@gmail.com>
>> ---
>> Documentation/user-manual.txt | 30 ++++++++++++++++++++++++++++++
>> 1 files changed, 30 insertions(+), 0 deletions(-)
>>
>> diff --git a/Documentation/user-manual.txt b/Documentation/user-manual.txt
>> index 3278aa7..a3032c7 100644
>> --- a/Documentation/user-manual.txt
>> +++ b/Documentation/user-manual.txt
>> @@ -40,6 +40,36 @@ without any explanation.
>> Finally, see <<todo>> for ways that you can help make this manual more
>> complete.
>
> I think a "getting started" section near the beginning of the manual is a
> good idea (and ll.40- is a very early part of the manual).
>
> For that "introductory" purpose, however, I'd suggest showing how they
> appear in the actual .git/config file first in the editor and then show a
> way to use the "git config" command as an alternative.
I disagree. Opening ~/.gitconfig will just open an empty file for the
new users, afterwards they'll just scratch their heads wondering, now
what?
If you first teach them to do 'git config --global color.ui auto'
they'll blindly enter the command but then when they open the file
they'll say "ahhh, so that's what happens".
>> +[[getting-started]]
>> +Getting started
>> +=============
>> +
>> +Git's configuration is distributed among different locations--this manual will
>> +only to deal with 'global' and 'repository' variables, where 'repository'
>> +variables take precedence over 'global' ones.
>> +
>> +You would probably want to start setting up something useful:
>> +------------------------------------------------
>> +$ git config --global color.ui auto
>> +------------------------------------------------
>> +
>> +This will make prettier the output of certain commands such as `git diff`, but
>> +that's not important; what is important here is that `color.ui` has been
>> +stored in the 'global' (for the user) configuration.
>
> "(for the user)" in parentheses here is better than not saying it
> anywhere, but I think you should have it in the first paragraph where you
> explain there are (at least) two kinds, global vs repository, in order to
> clarify what you mean by 'global' is not "system/site wide" but "in any
> repository I use" upfront.
Ok.
>> +View and manually modify the configuration with the `--edit`
>> +option (which will use '$EDITOR'):
>> +------------------------------------------------
>> +$ git config --global --edit
>> +[color]
>> + ui = auto
>> +------------------------------------------------
>
> Copies of user manual are found quite easily (and bookmarked by many
> people) on the web, and are looked at by people with not-so-bleeding-edge
> version of git, so I'd rather not to give them "config --edit" this early
> in the documentation. Perhaps after at least 6 months (preferrably a
> year) after a release that has the new option, we can start encouraging
> it, but not before. So I'd suggest replacing 'with the --edit ...' with
> '$HOME/.gitconfig with your favorite editor' or something like that for
> now.
Good point.
>> +Or you can manually edit the file which is located in `~/.gitconfig`. Other
>> +locations are `/etc/gitconfig` (system), and `.git/config` (repository).
>
> IOW, have this (without "Or") at the very beginning, and then as an
> alternative give "git config color.ui auto".
Read my first comment.
I'll send another round of patches.
--
Felipe Contreras
next prev parent reply other threads:[~2009-05-01 8:37 UTC|newest]
Thread overview: 18+ messages / expand[flat|nested] mbox.gz Atom feed top
2009-04-04 9:38 [PATCH 0/7] user-manual: general improvements Felipe Contreras
2009-04-04 9:38 ` [PATCH 1/7] user-manual: remove some git-foo usage Felipe Contreras
2009-04-04 9:38 ` [PATCH 2/7] docbook: improve css style Felipe Contreras
[not found] ` <1238837909-3060-4-git-send-email-felipe.contreras@gmail.com>
2009-04-04 9:38 ` [PATCH 4/7] user-manual: use 'fast-forward' instead of 'fast forward' Felipe Contreras
2009-04-04 9:38 ` [PATCH 5/7] user-manual: use SHA-1 instead of SHA1 or sha1 Felipe Contreras
2009-04-04 9:38 ` [PATCH 6/7] user-manual: add global config section Felipe Contreras
2009-04-04 9:38 ` [PATCH 7/7] user-manual: simplify the user configuration Felipe Contreras
2009-04-05 3:36 ` Jay Soffian
2009-04-05 9:14 ` Felipe Contreras
2009-04-05 15:11 ` Jay Soffian
2009-04-05 9:47 ` [PATCH 6/7] user-manual: add global config section Junio C Hamano
2009-05-01 8:37 ` Felipe Contreras [this message]
2009-05-01 22:08 ` Junio C Hamano
2009-05-01 22:51 ` Felipe Contreras
2009-05-02 0:16 ` Junio C Hamano
2009-04-06 8:14 ` [PATCH 5/7] user-manual: use SHA-1 instead of SHA1 or sha1 Junio C Hamano
2009-05-01 8:26 ` Felipe Contreras
2009-04-06 8:14 ` [PATCH 4/7] user-manual: use 'fast-forward' instead of 'fast forward' Junio C Hamano
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=94a0d4530905010137h772b53f1q8af0d30400a05043@mail.gmail.com \
--to=felipe.contreras@gmail.com \
--cc=git@vger.kernel.org \
--cc=gitster@pobox.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).