# [TopGit PATCH] README: Fix spelling

8 messages from 2008-11-20 to 2008-11-20. Participants: Jonas Fonseca, martin f krafft, Petr Baudis.
Thread: https://gitlist.dev/t/16411

## Jonas Fonseca, 2008-11-20 13:51

Subject: [TopGit PATCH] README: Fix spelling
Message-ID: <1227189062-11951-1-git-send-email-fonseca@diku.dk>
URL: https://gitlist.dev/e/1227189062-11951-1-git-send-email-fonseca%40diku.dk

```
Signed-off-by: Jonas Fonseca <fonseca@diku.dk>

---
 README[m |   11 [32m+++++[m[31m------[m
 1 files changed, 5 insertions(+), 6 deletions(-)[m

[1mdiff --git a/README b/README[m
[1mindex 5bfe3ee..9e291da 100644[m
[1m--- a/README[m
[1m+++ b/README[m
[36m@@ -22,7 +22,7 @@ version control of patches (reordering of patches is not[m
 version-controlled at all). But there are several disadvantages -[m
 for one, these tools (especially StGIT) do not actually fit well[m
 with plain Git at all: it is basically impossible to take advantage[m
[31m-of the index efectively when using StGIT. But more importantly,[m
[32m+[m[32mof the index effectively when using StGIT. But more importantly,[m
 these tools horribly fail in the face of distributed environment.[m
 [m
 TopGit has been designed around three main tenets:[m
[36m@@ -45,7 +45,7 @@ them.[m
 [m
 As mentioned above, the main intended use-case for TopGit is tracking[m
 third-party patches, where each patch is effectively a single topic[m
[31m-branch.  In order to flexibly accomodate even complex scenarios when[m
[32m+[m[32mbranch.  In order to flexibly accommodate even complex scenarios when[m
 you track many patches where many are independent but some depend[m
 on others, TopGit ignores the ancient Quilt heritage of patch series[m
 and instead allows the patches to freely form graphs (DAGs just like[m
[36m@@ -222,7 +222,7 @@ tg create[m
 [m
 	After `tg create`, you should insert the patch description[m
 	to the '.topmsg' file, which will already contain some[m
[31m-	pre-filled bits. You can set topgit.to, topgit.cc and topgit.bcc[m
[32m+[m	[32mprefilled bits. You can set topgit.to, topgit.cc and topgit.bcc[m
 	configuration variables in order to have `tg create`[m
 	add these headers with given default values to '.topmsg'.[m
 [m
[36m@@ -350,7 +350,7 @@ tg export[m
 	in the cleaned up history (corresponding basically exactly[m
 	to `tg patch` output for the topic branch).[m
 [m
[31m-	The command has two posible outputs now - either a Git branch[m
[32m+[m	[32mThe command has two possible outputs now - either a Git branch[m
 	with the collapsed history, or a quilt series in new directory.[m
 [m
 	In case of producing collapsed history in new branch,[m
[36m@@ -455,7 +455,6 @@ tg update[m
 [m
 	TODO: tg update -a for updating all topic branches[m
 [m
[31m-TODO: tg depend for adding/removing dependencies smoothly[m
 TODO: tg rename[m
 [m
 [m
[36m@@ -485,7 +484,7 @@ whatever Cc headers you choose or the post-three-dashes message.[m
 When mailing out your patch, basically only few extra headers[m
 mail headers are inserted and the patch itself is appended.[m
 Thus, as your patches evolve, you can record nuances like whether[m
[31m-the paricular patch should have To-list/Cc-maintainer or vice[m
[32m+[m[32mthe particular patch should have To-list/Cc-maintainer or vice[m
 versa and similar nuances, if your project is into that.[m
 From is prefilled from your current GIT_AUTHOR_IDENT, other headers[m
 can be prefilled from various optional topgit.* config options.[m
-- 
tg: (f17218e..) jf/readme-update (depends on: master)

```

## Jonas Fonseca, 2008-11-20 13:52

Subject: Re: [TopGit PATCH] README: Fix spelling
Message-ID: <2c6b72b30811200552h46004299w881ad61134ec5555@mail.gmail.com>
URL: https://gitlist.dev/e/2c6b72b30811200552h46004299w881ad61134ec5555%40mail.gmail.com
In-Reply-To: <1227189062-11951-1-git-send-email-fonseca@diku.dk>

```
Oops sorry about this one!!! :-/

On Thu, Nov 20, 2008 at 14:51, Jonas Fonseca <fonseca@diku.dk> wrote:
> Signed-off-by: Jonas Fonseca <fonseca@diku.dk>
>
> ---
>  README [m |   11  [32m+++++ [m [31m------ [m
>  1 files changed, 5 insertions(+), 6 deletions(-) [m
>
>  [1mdiff --git a/README b/README [m
>  [1mindex 5bfe3ee..9e291da 100644 [m
>  [1m--- a/README [m
>  [1m+++ b/README [m
>  [36m@@ -22,7 +22,7 @@ version control of patches (reordering of patches is not [m
>  version-controlled at all). But there are several disadvantages - [m
>  for one, these tools (especially StGIT) do not actually fit well [m
>  with plain Git at all: it is basically impossible to take advantage [m
>  [31m-of the index efectively when using StGIT. But more importantly, [m
>  [32m+ [m [32mof the index effectively when using StGIT. But more importantly, [m
>  these tools horribly fail in the face of distributed environment. [m
>  [m
>  TopGit has been designed around three main tenets: [m
>  [36m@@ -45,7 +45,7 @@ them. [m
>  [m
>  As mentioned above, the main intended use-case for TopGit is tracking [m
>  third-party patches, where each patch is effectively a single topic [m
>  [31m-branch.  In order to flexibly accomodate even complex scenarios when [m
>  [32m+ [m [32mbranch.  In order to flexibly accommodate even complex scenarios when [m
>  you track many patches where many are independent but some depend [m
>  on others, TopGit ignores the ancient Quilt heritage of patch series [m
>  and instead allows the patches to freely form graphs (DAGs just like [m
>  [36m@@ -222,7 +222,7 @@ tg create [m
>  [m
>        After `tg create`, you should insert the patch description [m
>        to the '.topmsg' file, which will already contain some [m
>  [31m-  pre-filled bits. You can set topgit.to, topgit.cc and topgit.bcc [m
>  [32m+ [m        [32mprefilled bits. You can set topgit.to, topgit.cc and topgit.bcc [m
>        configuration variables in order to have `tg create` [m
>        add these headers with given default values to '.topmsg'. [m
>  [m
>  [36m@@ -350,7 +350,7 @@ tg export [m
>        in the cleaned up history (corresponding basically exactly [m
>        to `tg patch` output for the topic branch). [m
>  [m
>  [31m-  The command has two posible outputs now - either a Git branch [m
>  [32m+ [m        [32mThe command has two possible outputs now - either a Git branch [m
>        with the collapsed history, or a quilt series in new directory. [m
>  [m
>        In case of producing collapsed history in new branch, [m
>  [36m@@ -455,7 +455,6 @@ tg update [m
>  [m
>        TODO: tg update -a for updating all topic branches [m
>  [m
>  [31m-TODO: tg depend for adding/removing dependencies smoothly [m
>  TODO: tg rename [m
>  [m
>  [m
>  [36m@@ -485,7 +484,7 @@ whatever Cc headers you choose or the post-three-dashes message. [m
>  When mailing out your patch, basically only few extra headers [m
>  mail headers are inserted and the patch itself is appended. [m
>  Thus, as your patches evolve, you can record nuances like whether [m
>  [31m-the paricular patch should have To-list/Cc-maintainer or vice [m
>  [32m+ [m [32mthe particular patch should have To-list/Cc-maintainer or vice [m
>  versa and similar nuances, if your project is into that. [m
>  From is prefilled from your current GIT_AUTHOR_IDENT, other headers [m
>  can be prefilled from various optional topgit.* config options. [m
> --
> tg: (f17218e..) jf/readme-update (depends on: master)
>



-- 
Jonas Fonseca

```

## Jonas Fonseca, 2008-11-20 13:57

Subject: [TopGit PATCH] tg patch: disable pager and colors for git-diff
Message-ID: <20081120135710.GA16303@diku.dk>
URL: https://gitlist.dev/e/20081120135710.GA16303%40diku.dk
In-Reply-To: <1227189062-11951-1-git-send-email-fonseca@diku.dk>

```
When output is not redirected to a file, git brings up the pager for
only the diff, which can be confusing, so disable with --no-pager.
git-diff is a porcelain command and thus subject to color options. Use
--no-color, to avoid the patch being corrupted with terminal escape
characters when color.diff=always.

Signed-off-by: Jonas Fonseca <fonseca@diku.dk>
---
 tg-patch.sh |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

 Jonas Fonseca <fonseca@diku.dk> wrote Thu, Nov 20, 2008:
 > Signed-off-by: Jonas Fonseca <fonseca@diku.dk>
 > 
 > ---
 >  README[m |   11 [32m+++++[m[31m------[m
 >  1 files changed, 5 insertions(+), 6 deletions(-)[m
 > 
 > [1mdiff --git a/README b/README[m
 > [1mindex 5bfe3ee..9e291da 100644[m
 > [1m--- a/README[m
 > [1m+++ b/README[m

 I hope this demonstrates the point of this patch. ;)

diff --git a/tg-patch.sh b/tg-patch.sh
index 97338ab..c2f1b56 100644
--- a/tg-patch.sh
+++ b/tg-patch.sh
@@ -34,7 +34,7 @@ git diff-tree --name-only "$base_rev" "$name" |
 	fgrep -vx ".topdeps" |
 	fgrep -vx ".topmsg" >"$git_is_stupid" || : # fgrep likes to fail randomly?
 if [ -s "$git_is_stupid" ]; then
-	cat "$git_is_stupid" | xargs git diff --patch-with-stat "$base_rev" "$name" --
+	cat "$git_is_stupid" | xargs git --no-pager diff --no-color --patch-with-stat "$base_rev" "$name" --
 else
 	echo "No changes."
 fi
-- 
tg: (f17218e..) jf/patch-no-pager-and-color (depends on: master)

-- 
Jonas Fonseca

```

## martin f krafft, 2008-11-20 14:17

Subject: Re: [TopGit PATCH] README: Fix spelling
Message-ID: <20081120141725.GB25425@piper.oerlikon.madduck.net>
URL: https://gitlist.dev/e/20081120141725.GB25425%40piper.oerlikon.madduck.net
In-Reply-To: <2c6b72b30811200552h46004299w881ad61134ec5555@mail.gmail.com>

```
also sprach Jonas Fonseca <jonas.fonseca@gmail.com> [2008.11.20.1452 +0100]:
> Oops sorry about this one!!! :-/

What about it? The patch seems perfectly alright. Only the quoted
version is broken, which I think is your fault.

Should I apply the README patch?

-- 
 .''`.   martin f. krafft <madduck@debian.org>
: :'  :  proud Debian developer, author, administrator, and user
`. `'`   http://people.debian.org/~madduck - http://debiansystem.info
  `-  Debian - when you have better things to do than fixing systems
 
a Hooloovoo is a superintelligent shade of the color blue.
            -- douglas adams, "the hitchhiker's guide to the galaxy"

```

## Jonas Fonseca, 2008-11-20 14:23

Subject: Re: [TopGit PATCH] README: Fix spelling
Message-ID: <2c6b72b30811200623t3326f69bu4c8570a3c41cc764@mail.gmail.com>
URL: https://gitlist.dev/e/2c6b72b30811200623t3326f69bu4c8570a3c41cc764%40mail.gmail.com
In-Reply-To: <20081120141725.GB25425@piper.oerlikon.madduck.net>

```
On Thu, Nov 20, 2008 at 15:17, martin f krafft <madduck@debian.org> wrote:
> also sprach Jonas Fonseca <jonas.fonseca@gmail.com> [2008.11.20.1452 +0100]:
>> Oops sorry about this one!!! :-/
>
> What about it? The patch seems perfectly alright. Only the quoted
> version is broken, which I think is your fault.

Well, it looks very broken in Gmail ...

> Should I apply the README patch?

Yes, if you can salvage it. Else it is also available in branch
jf/readme-update at

  git://repo.or.cz/topgit/fonseca.git

-- 
Jonas Fonseca

```

## Petr Baudis, 2008-11-20 14:34

Subject: Re: [TopGit PATCH] tg patch: disable pager and colors for git-diff
Message-ID: <20081120143455.GH10544@machine.or.cz>
URL: https://gitlist.dev/e/20081120143455.GH10544%40machine.or.cz
In-Reply-To: <20081120135710.GA16303@diku.dk>

```
On Thu, Nov 20, 2008 at 02:57:10PM +0100, Jonas Fonseca wrote:
> When output is not redirected to a file, git brings up the pager for
> only the diff, which can be confusing, so disable with --no-pager.
> git-diff is a porcelain command and thus subject to color options. Use
> --no-color, to avoid the patch being corrupted with terminal escape
> characters when color.diff=always.
> 
> Signed-off-by: Jonas Fonseca <fonseca@diku.dk>

I still don't understand how did that color thing happen - shouldn't
git diff avoid spewing out colors when the output is not a tty? And when
it is, I want the colors myself, too.

Good point with the --no-pager, but in that case, tg patch itself should
by default invoke the pager, since it really is very desirable.

-- 
				Petr "Pasky" Baudis
People who take cold baths never have rheumatism, but they have
cold baths.

```

## Jonas Fonseca, 2008-11-20 14:55

Subject: Re: [TopGit PATCH] tg patch: disable pager and colors for git-diff
Message-ID: <2c6b72b30811200655o770efd63u4101f44683f2bc0d@mail.gmail.com>
URL: https://gitlist.dev/e/2c6b72b30811200655o770efd63u4101f44683f2bc0d%40mail.gmail.com
In-Reply-To: <20081120143455.GH10544@machine.or.cz>

```
On Thu, Nov 20, 2008 at 15:34, Petr Baudis <pasky@suse.cz> wrote:
> On Thu, Nov 20, 2008 at 02:57:10PM +0100, Jonas Fonseca wrote:
>> When output is not redirected to a file, git brings up the pager for
>> only the diff, which can be confusing, so disable with --no-pager.
>> git-diff is a porcelain command and thus subject to color options. Use
>> --no-color, to avoid the patch being corrupted with terminal escape
>> characters when color.diff=always.
>>
>> Signed-off-by: Jonas Fonseca <fonseca@diku.dk>
>
> I still don't understand how did that color thing happen - shouldn't
> git diff avoid spewing out colors when the output is not a tty? And when
> it is, I want the colors myself, too.

As I wrote in the commit message, git diff always spews out colors
with color.diff=always. This was what I for experimental reasons had
in my .git/config (and forgotten all about) before sending the README
update patch. Topgit could check the git color configuration but that
seems more hacky.

> Good point with the --no-pager, but in that case, tg patch itself should
> by default invoke the pager, since it really is very desirable.

Yes, probably.

-- 
Jonas Fonseca

```

## Petr Baudis, 2008-11-20 15:07

Subject: Re: [TopGit PATCH] tg patch: disable pager and colors for git-diff
Message-ID: <20081120150754.GH10491@machine.or.cz>
URL: https://gitlist.dev/e/20081120150754.GH10491%40machine.or.cz
In-Reply-To: <2c6b72b30811200655o770efd63u4101f44683f2bc0d@mail.gmail.com>

```
On Thu, Nov 20, 2008 at 03:55:47PM +0100, Jonas Fonseca wrote:
> On Thu, Nov 20, 2008 at 15:34, Petr Baudis <pasky@suse.cz> wrote:
> > On Thu, Nov 20, 2008 at 02:57:10PM +0100, Jonas Fonseca wrote:
> >> When output is not redirected to a file, git brings up the pager for
> >> only the diff, which can be confusing, so disable with --no-pager.
> >> git-diff is a porcelain command and thus subject to color options. Use
> >> --no-color, to avoid the patch being corrupted with terminal escape
> >> characters when color.diff=always.
> >>
> >> Signed-off-by: Jonas Fonseca <fonseca@diku.dk>
> >
> > I still don't understand how did that color thing happen - shouldn't
> > git diff avoid spewing out colors when the output is not a tty? And when
> > it is, I want the colors myself, too.
> 
> As I wrote in the commit message, git diff always spews out colors
> with color.diff=always. This was what I for experimental reasons had
> in my .git/config (and forgotten all about) before sending the README
> update patch. Topgit could check the git color configuration but that
> seems more hacky.

This shows just that color.diff=always is asking for trouble. ;-)
I think we shouldn't try to outsmart the user if they _force_ that they
really always want the colors.

-- 
				Petr "Pasky" Baudis
People who take cold baths never have rheumatism, but they have
cold baths.

```
