Git development
 help / color / mirror / Atom feed
* Re: Pingback/Trackback for Git?
From: Junio C Hamano @ 2007-07-04  5:10 UTC (permalink / raw)
  To: Thomas Perl; +Cc: git
In-Reply-To: <372f54da0707030512k79e2dc74m98bf0a690abffc4a@mail.gmail.com>

"Thomas Perl" <th.perl@gmail.com> writes:

> I've outlined some ideas here, feel free to suggest implementations or
> point out problems:
>
> http://tperl.blogspot.com/2007/07/pingbacktrackback-for-git.html

It was unclear to me who does what and when in the overall
picture you envision after reading that page.  You seem to
assume there is a prominent ping/trackback repository that
everybody who is interested looks at.  Who updates it?  When?
With what?  How does the namespace inside that repository
managed, if managed in any way?  Given a project name, how does
one learn which pick/grackback repository (and perhaps which
branch) to go to to learn the current status about it?

^ permalink raw reply

* Re: [PATCH] glossary: add 'reflog'
From: Junio C Hamano @ 2007-07-04  5:10 UTC (permalink / raw)
  To: Johannes Schindelin; +Cc: git
In-Reply-To: <Pine.LNX.4.64.0707032128020.4071@racer.site>

Thanks.

^ permalink raw reply

* Re: [PATCH] Don't smash stack when $GIT_ALTERNATE_OBJECT_DIRECTORIES is too long
From: Junio C Hamano @ 2007-07-04  5:10 UTC (permalink / raw)
  To: Jim Meyering; +Cc: git
In-Reply-To: <87k5thdb3f.fsf@rho.meyering.net>

Thanks.

^ permalink raw reply

* Re: [PATCH] repack: don't report "Nothing new to pack." if -q is given
From: Junio C Hamano @ 2007-07-04  5:10 UTC (permalink / raw)
  To: Uwe Kleine-König; +Cc: Git Mailing List
In-Reply-To: <20070703084757.GA4694@lala>

Uwe Kleine-König  <ukleinek@informatik.uni-freiburg.de> writes:

> Signed-off-by: Uwe Kleine-König <ukleinek@informatik.uni-freiburg.de>
> ---
> This patch is on top of maint.  For master and next you need
> s/name/names/.

Thanks.  But I won't be applying this to 'maint' for now; I do
not think it is big enough bugfix.

^ permalink raw reply

* Re: [Qgit RFC] commit --amend
From: Junio C Hamano @ 2007-07-04  5:10 UTC (permalink / raw)
  To: Jan Hudec; +Cc: Marco Costalba, git
In-Reply-To: <20070702180309.GA4400@efreet.light.src>

Jan Hudec <bulb@ucw.cz> writes:

>> P.S: Why 'git-commit --amend -F' it's explicitely forbidden?

The reasoning goes like this (here, I am not particularly trying
to justify it, but am merely explaining the original reasoning
and intended use case as a historical background):

    To amend means to remove the tip commit, replace with a new
    one, possibly but not necessarily with a different tree from
    the removed one.

    Since you are "amending", the spirit of the commit you are
    going to create, in order to replace the old one, ought to
    be the same as the one being replaced.

    - You may be only adding a change that you forgot to add
      before making the previous commit (in which case your tree
      is slightly different, but what you are going to say in
      the commit log message is exactly the same), or

    - you may found a typo in the commit log message and trying
      to fix it (in which case your tree is identical but the
      commit log message would be slightly different).

    In either case, the resulting commit log message would be
    very similar to the existing one, so the tool helps you by
    letting re-use and re-edit the commit log message instead of
    forcing you to re-type it.

There is no room for -F, -c, nor -m to make sense for these use
cases, and giving them to "commit --amend" is most likely a user
error, and diagnozed as such, because "commit --amend" is an
end-user level Porcelain program.

If you are popping one commit and replacing with a totally
**unrelated** commit, that is not what --amend is about.  What
you are doing is "reset --soft HEAD^" followed by "add <something>"
followed by "commit".

At the mechanical level, you could argue that --amend is doing
the same thing.  After all, that reset/add/commit sequence is
exactly what is done by --amend internally.

But if a Porcelain like StGIT or Qgit would want to do that kind
of operation for different use case than "amending", it can and
should use plumbing commands, just like the implementation of
"commit --amend" does, with different constraints and error
checks.

^ permalink raw reply

* Re: [PATCH 1/2] Remove obsolete commit-walkers
From: Junio C Hamano @ 2007-07-04  5:10 UTC (permalink / raw)
  To: Bill Lear; +Cc: Daniel Barkalow, git
In-Reply-To: <18058.17778.692974.122271@lisa.zopyra.com>

Bill Lear <rael@zopyra.com> writes:

> On Monday, July 2, 2007 at 23:22:05 (-0700) Junio C Hamano writes:
>>I'll apply this after 1.5.3.  In the meantime, I'll do this for 1.5.3.
>>
>>diff --git a/Documentation/git-local-fetch.txt b/Documentation/git-local-fetch.txt
>>index 19b5f88..141b767 100644
>>--- a/Documentation/git-local-fetch.txt
>>+++ b/Documentation/git-local-fetch.txt
>>@@ -14,6 +14,8 @@ SYNOPSIS
>> 
>> DESCRIPTION
>> -----------
>>+THIS COMMAND IS DEPRECATED.
>>...
>
> If a deprecated command has a replacement, the deprecation notice
> should point the user to that.

Actually these fetch backend shouldn't even be needed by the end
users.  "git fetch" simply does not drive them these days.

^ permalink raw reply

* Re: [PATCH] git-submodule: provide easy way of adding new submodules
From: Junio C Hamano @ 2007-07-04  5:10 UTC (permalink / raw)
  To: skimo; +Cc: git, Lars Hjemli
In-Reply-To: <20070703154732.GO7969MdfPADPa@greensroom.kotnet.org>

Sven Verdoolaege <skimo@kotnet.org> writes:

> On Mon, Jun 25, 2007 at 12:09:09AM -0700, Junio C Hamano wrote:
>> I am not sure about the usefulness of "-b branch" thing myself,
>> but other than that, looks very sane to me.
>
> So, do you want me to send it in again, without the branch thing?

It is already scheduled for 1.5.3 and is part of 'master'.

^ permalink raw reply

* Re: [PATCH] Correctly document the name of the global excludes file configuration
From: Junio C Hamano @ 2007-07-04  5:10 UTC (permalink / raw)
  To: Michael Hendricks; +Cc: git
In-Reply-To: <11833949141179-git-send-email-michael@ndrix.org>

Well spotted, thanks.

^ permalink raw reply

* Re: Usability of git-update-ref <headname>
From: Junio C Hamano @ 2007-07-04  4:12 UTC (permalink / raw)
  To: Martin Langhoff; +Cc: Git Mailing List
In-Reply-To: <46a038f90707031908x3fb2eb59ob0a57a33777363fb@mail.gmail.com>

"Martin Langhoff" <martin.langhoff@gmail.com> writes:

> Am I using the wrong command? I'd be happy to remove the bogus head
> and create a new one, but I don't think we have git-rm-ref.

Yes you are.  Forget about update-ref.  That is strictly for
script consumption.

>  # I think I'm on master, but I'm acually on maint
>  git-branch foo-feature
>  git-checkout foo-feature
>
>  # realise I've branched in the wrong place

   $ git reset --soft master

^ permalink raw reply

* Usability of git-update-ref <headname>
From: Martin Langhoff @ 2007-07-04  2:08 UTC (permalink / raw)
  To: Git Mailing List

A few times now I've done the following

  # I think I'm on master, but I'm acually on maint
  git-branch foo-feature
  git-checkout foo-feature

  # realise I've branched in the wring place
  git-update-ref foo-feature master

And from that point, all sorts of things go weird, because I should have said

  git-update-ref refs/heads/foo-feature master

to fix it up I have to manually rm .git/foo-feature -- and I can't see
a way to remove a ref with git-update-ref, so if I was using packed
refs I'd be in trouble ;-)

Am I using the wrong command? I'd be happy to remove the bogus head
and create a new one, but I don't think we have git-rm-ref.



m

^ permalink raw reply

* Re: [PATCH] fsck --lost-found writes to subdirectories in .git/lost-found/
From: Johannes Schindelin @ 2007-07-04  1:41 UTC (permalink / raw)
  To: Jonas Fonseca; +Cc: Junio C Hamano, git
In-Reply-To: <20070704013311.GA32210@diku.dk>

Hi,

On Wed, 4 Jul 2007, Jonas Fonseca wrote:

> -	Write dangling refs into .git/commit/ or .git/other/, depending
> -	on type.
> +	Write dangling refs into .git/lost-found/commit/ or
> +	.git/lost-found/other/, depending on type.

Oooooops.

Thanks,
Dscho

^ permalink raw reply

* [PATCH] fsck --lost-found writes to subdirectories in .git/lost-found/
From: Jonas Fonseca @ 2007-07-04  1:33 UTC (permalink / raw)
  To: Johannes Schindelin; +Cc: Junio C Hamano, git
In-Reply-To: <Pine.LNX.4.64.0707030133060.4071@racer.site>

Signed-off-by: Jonas Fonseca <fonseca@diku.dk>
---
 Documentation/git-fsck.txt |    4 ++--
 1 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/Documentation/git-fsck.txt b/Documentation/git-fsck.txt
index 08512e0..1a432f2 100644
--- a/Documentation/git-fsck.txt
+++ b/Documentation/git-fsck.txt
@@ -65,8 +65,8 @@ index file and all SHA1 references in .git/refs/* as heads.
 	Be chatty.
 
 --lost-found::
-	Write dangling refs into .git/commit/ or .git/other/, depending
-	on type.
+	Write dangling refs into .git/lost-found/commit/ or
+	.git/lost-found/other/, depending on type.
 
 It tests SHA1 and general object sanity, and it does full tracking of
 the resulting reachability and everything else. It prints out any
-- 
1.5.2.2.1451.gb0e5e

-- 
Jonas Fonseca

^ permalink raw reply related

* Re: [PATCH] git-repack: generational repacking (and example hook script)
From: Johannes Schindelin @ 2007-07-04  1:01 UTC (permalink / raw)
  To: Sam Vilain; +Cc: Nicolas Pitre, Junio C Hamano, git
In-Reply-To: <468AE462.1040202@vilain.net>

Hi,

On Wed, 4 Jul 2007, Sam Vilain wrote:

> Nicolas Pitre wrote:
> >> 1. Do you agree that some users would want their git repositories to be
> >> "maintenance free"?
> >
> > I'm not so sure.
> 
> Well, no offence, but I think you should withhold from voicing a
> fundamental concern as this, because you're not one of its target users.

Let's put it this way. A lot of car drivers would probably agree that it 
is a Good Thing (tm) if their car automatically went to get gas, before it 
ran out of it. Less hassle, right?

Yes, except if your car decides to get gas when you are already late, 
speeding, trying to catch your plane.

Same holds for Git. Is is worth the hassle having to wait for this 
automatic git-gc when your boss is waiting impatiently for you to show 
some results?

Now, you seem to argue that the cost of a single git-gc should be 
decreased. But I maintain that the _usefulness_ of git-gc is decreased 
that way, too.

In all of my projects, the most efficient setup is one big pack. That is 
why I set up some cronjobs on the machines that run 24/7, and that is why 
I run "git-gc --prune" when idling, on almost all my repos.

Ciao,
Dscho

^ permalink raw reply

* gitk - fails to highlight commits
From: Mark Levedahl @ 2007-07-04  0:44 UTC (permalink / raw)
  To: Paul Mackerras; +Cc: Git Mailing List

Using gitk on master (281404ca1db4c921ac162f3c0 in the gitk) gitk's 
highlighting is sporadic. Running gitk from a gitk sandbox and typing 
'gitk' into the 'Highlight Commits' box shows nothing highlighted, but 
all commits should be highlighted. After doing this, many of the commits 
revealed by scrolling down the list are highlighted, just not the ones 
visisble at the top nor the first few below.

This problem first appears in commit 322a8cc ("gitk: New algorithm for 
drawing the graph lines).

Mark

^ permalink raw reply

* Re: [PATCH] git-repack: generational repacking (and example hook script)
From: Sam Vilain @ 2007-07-04  0:05 UTC (permalink / raw)
  To: Nicolas Pitre; +Cc: Junio C Hamano, git
In-Reply-To: <alpine.LFD.0.999.0707031020300.26459@xanadu.home>

Nicolas Pitre wrote:
>> 1. Do you agree that some users would want their git repositories to be
>> "maintenance free"?
>
> I'm not so sure.

Well, no offence, but I think you should withhold from voicing a
fundamental concern as this, because you're not one of its target users.

I'd be more than happy to reshape the patch so that it does not
introduce this "complexity" into the current code path.  Potentially it
could entirely fit into the post-commit hook, which should not upset
anybody as they don't have to turn it on.  I just noticed that the
"repack -a" code path was already doing a lot of what a generational
repack would have to do, so thought I'd re-use the code.

Of course your critical analysis of code is more than welcome.

> And even if your developers are completely inept to the point of not 
> wanting to run 'git gc' once a week for example, 

This kind of characterisation does not help the discussion.

> I'm sure you can automate 
> some of that maintenance asynchronously from a simple post commit hook 
> or something, based on the output of 'git count-objects -v'.

Yet another little command that I didn't know about that could make the
 patch simpler.

Potentially the calculations could be performed in count-objects.  I'll
investigate that.

>> 2. Do you agree that having thousands of packs would add measurable
>> overhead?
> 
> Sure it would, but far less as it used to when we last discussed this 
> since performances in those cases has been improved significantly.

Far less for examining recent history.  It would however make examining
older history, and potentially blame operations slower.  Just how much
slower I don't know, but I'd guess that random access with 1000 small
indices scanned sequentially is slower than with 10 larger indices.

> And if you end up with thousands of packs in the first place I think you 
> have a more fundamental problem to fix, something that generational 
> repacking would just paper over.

Right, but only if you are of the opinion that a repack is something
that is best run off-line from normal work flow.  If you want it to run
in-line, then the fundamental problem would be "a simple operation now
takes much longer because a huge repack is occurring".

So I think this fundamental decision is more of a user preference.

Sam.

^ permalink raw reply

* [PATCH] Document git-filter-branch
From: Johannes Schindelin @ 2007-07-03 23:41 UTC (permalink / raw)
  To: Frank Lichtenheld; +Cc: git, gitster
In-Reply-To: <20070703220540.GN12721@planck.djpig.de>


This moves the documentation in git-filter-branch.sh to its own
man page, with a few touch ups (incorporating comments by Frank
Lichtenheld).

Signed-off-by: Johannes Schindelin <johannes.schindelin@gmx.de>
---

	Changes as per my other reply to you. I kinda waited for the 
	emphasis hint, but I guess it's bed time in Germany.

 Documentation/cmd-list.perl         |    1 +
 Documentation/git-filter-branch.txt |  262 +++++++++++++++++++++++++++++++++++
 git-filter-branch.sh                |  187 +------------------------
 3 files changed, 266 insertions(+), 184 deletions(-)
 create mode 100644 Documentation/git-filter-branch.txt

diff --git a/Documentation/cmd-list.perl b/Documentation/cmd-list.perl
index f50f613..2143995 100755
--- a/Documentation/cmd-list.perl
+++ b/Documentation/cmd-list.perl
@@ -105,6 +105,7 @@ git-diff-tree                           plumbinginterrogators
 git-fast-import				ancillarymanipulators
 git-fetch                               mainporcelain
 git-fetch-pack                          synchingrepositories
+git-filter-branch                       ancillarymanipulators
 git-fmt-merge-msg                       purehelpers
 git-for-each-ref                        plumbinginterrogators
 git-format-patch                        mainporcelain
diff --git a/Documentation/git-filter-branch.txt b/Documentation/git-filter-branch.txt
new file mode 100644
index 0000000..2074f31
--- /dev/null
+++ b/Documentation/git-filter-branch.txt
@@ -0,0 +1,262 @@
+git-filter-branch(1)
+====================
+
+NAME
+----
+git-filter-branch - Rewrite branches
+
+SYNOPSIS
+--------
+[verse]
+'git-filter-branch' [--env-filter <command>] [--tree-filter <command>]
+	[--index-filter <command>] [--parent-filter <command>]
+	[--msg-filter <command>] [--commit-filter <command>]
+	[--tag-name-filter <command>] [--subdirectory-filter <directory>]
+	[-d <directory>] <new-branch-name> [<rev-list options>...]
+
+DESCRIPTION
+-----------
+Lets you rewrite git revision history by creating a new branch from
+your current branch, applying custom filters on each revision.
+Those filters can modify each tree (e.g. removing a file or running
+a perl rewrite on all files) or information about each commit.
+Otherwise, all information (including original commit times or merge
+information) will be preserved.
+
+The command takes the new branch name as a mandatory argument and
+the filters as optional arguments.  If you specify no filters, the
+commits will be recommitted without any changes, which would normally
+have no effect and result in the new branch pointing to the same
+branch as your current branch.  Nevertheless, this may be useful in
+the future for compensating for some git bugs or such, therefore
+such a usage is permitted.
+
+WARNING! The rewritten history will have different object names for all
+the objects and will not converge with the original branch.  You will not
+be able to easily push and distribute the rewritten branch on top of the
+original branch.  Please do not use this command if you do not know the
+full implications, and avoid using it anyway, if a simple single commit
+would suffice to fix your problem.
+
+Always verify that the rewritten version is correct before disposing
+the original branch.
+
+Note that since this operation is extensively I/O expensive, it might
+be a good idea to redirect the temporary directory off-disk, e.g. on
+tmpfs.  Reportedly the speedup is very noticeable.
+
+
+Filters
+~~~~~~~
+
+The filters are applied in the order as listed below.  The <command>
+argument is always evaluated in shell using the 'eval' command.
+Prior to that, the $GIT_COMMIT environment variable will be set to contain
+the id of the commit being rewritten.  Also, GIT_AUTHOR_NAME,
+GIT_AUTHOR_EMAIL, GIT_AUTHOR_DATE, GIT_COMMITTER_NAME, GIT_COMMITTER_EMAIL,
+and GIT_COMMITTER_DATE is set according to the current commit.
+
+A 'map' function is available that takes an "original sha1 id" argument
+and outputs a "rewritten sha1 id" if the commit has been already
+rewritten, fails otherwise; the 'map' function can return several
+ids on separate lines if your commit filter emitted multiple commits.
+
+
+OPTIONS
+-------
+
+--env-filter <command>::
+	This is the filter for modifying the environment in which
+	the commit will be performed.  Specifically, you might want
+	to rewrite the author/committer name/email/time environment
+	variables (see gitlink:git-commit[1] for details).  Do not forget
+	to re-export the variables.
+
+--tree-filter <command>::
+	This is the filter for rewriting the tree and its contents.
+	The argument is evaluated in shell with the working
+	directory set to the root of the checked out tree.  The new tree
+	is then used as-is (new files are auto-added, disappeared files
+	are auto-removed - neither .gitignore files nor any other ignore
+	rules HAVE ANY EFFECT!).
+
+--index-filter <command>::
+	This is the filter for rewriting the index.  It is similar to the
+	tree filter but does not check out the tree, which makes it much
+	faster.  For hairy cases, see gitlink:git-update-index[1].
+
+--parent-filter <command>::
+	This is the filter for rewriting the commit's parent list.
+	It will receive the parent string on stdin and shall output
+	the new parent string on stdout.  The parent string is in
+	a format accepted by gitlink:git-commit-tree[1]: empty for
+	the initial commit, "-p parent" for a normal commit and
+	"-p parent1 -p parent2 -p parent3 ..." for a merge commit.
+
+--msg-filter <command>::
+	This is the filter for rewriting the commit messages.
+	The argument is evaluated in the shell with the original
+	commit message on standard input; its standard output is
+	used as the new commit message.
+
+--commit-filter <command>::
+	This is the filter for performing the commit.
+	If this filter is specified, it will be called instead of the
+	gitlink:git-commit-tree[1] command, with arguments of the form
+	"<TREE_ID> [-p <PARENT_COMMIT_ID>]..." and the log message on
+	stdin.  The commit id is expected on stdout.
++
+As a special extension, the commit filter may emit multiple
+commit ids; in that case, ancestors of the original commit will
+have all of them as parents.
+
+--tag-name-filter <command>::
+	This is the filter for rewriting tag names. When passed,
+	it will be called for every tag ref that points to a rewritten
+	object (or to a tag object which points to a rewritten object).
+	The original tag name is passed via standard input, and the new
+	tag name is expected on standard output.
++
+The original tags are not deleted, but can be overwritten;
+use "--tag-name-filter=cat" to simply update the tags.  In this
+case, be very careful and make sure you have the old tags
+backed up in case the conversion has run afoul.
++
+Note that there is currently no support for proper rewriting of
+tag objects; in layman terms, if the tag has a message or signature
+attached, the rewritten tag won't have it.  Sorry.  (It is by
+definition impossible to preserve signatures at any rate.)
+
+--subdirectory-filter <directory>::
+	Only ever look at the history, which touches the given subdirectory.
+	The result will contain that directory as its project root.
+
+-d <directory>::
+	Use this option to set the path to the temporary directory used for
+	rewriting.  When applying a tree filter, the command needs to
+	temporary checkout the tree to some directory, which may consume
+	considerable space in case of large projects.  By default it
+	does this in the '.git-rewrite/' directory but you can override
+	that choice by this parameter.
+
+<rev-list-options>::
+	When options are given after the new branch name, they will
+	be passed to gitlink:git-rev-list[1].  Only commits in the resulting
+	output will be filtered, although the filtered commits can still
+	reference parents which are outside of that set.
+
+
+Examples
+--------
+
+Suppose you want to remove a file (containing confidential information
+or copyright violation) from all commits:
+
+-------------------------------------------------------
+git filter-branch --tree-filter 'rm filename' newbranch
+-------------------------------------------------------
+
+A significantly faster version:
+
+-------------------------------------------------------------------------------
+git filter-branch --index-filter 'git update-index --remove filename' newbranch
+-------------------------------------------------------------------------------
+
+Now, you will get the rewritten history saved in the branch 'newbranch'
+(your current branch is left untouched).
+
+To "etch-graft" a commit to the revision history (set a commit to be
+the parent of the current initial commit and propagate that):
+
+----------------------------------------------------------------------
+git filter-branch --parent-filter sed\ 's/^$/-p <graft-id>/' newbranch
+----------------------------------------------------------------------
+
+(if the parent string is empty - therefore we are dealing with the
+initial commit - add graftcommit as a parent).  Note that this assumes
+history with a single root (that is, no merge without common ancestors
+happened).  If this is not the case, use:
+
+-------------------------------------------------------------------------------
+git filter-branch --parent-filter \
+	'cat; test $GIT_COMMIT = <commit-id> && echo "-p <graft-id>"' newbranch
+-------------------------------------------------------------------------------
+
+To remove commits authored by "Darl McBribe" from the history:
+
+------------------------------------------------------------------------------
+git filter-branch --commit-filter '
+	if [ "$GIT_AUTHOR_NAME" = "Darl McBribe" ];
+	then
+		shift;
+		while [ -n "$1" ];
+		do
+			shift;
+			echo "$1";
+			shift;
+		done;
+	else
+		git commit-tree "$@";
+	fi' newbranch
+------------------------------------------------------------------------------
+
+The shift magic first throws away the tree id and then the -p
+parameters.  Note that this handles merges properly! In case Darl
+committed a merge between P1 and P2, it will be propagated properly
+and all children of the merge will become merge commits with P1,P2
+as their parents instead of the merge commit.
+
+To restrict rewriting to only part of the history, specify a revision
+range in addition to the new branch name.  The new branch name will
+point to the top-most revision that a 'git rev-list' of this range
+will print.
+
+Note that the changes introduced by the commits, and not reverted by
+subsequent commits, will still be in the rewritten branch. If you want
+to throw out _changes_ together with the commits, you should use the
+interactive mode of gitlink:git-rebase[1].
+
+Consider this history:
+
+------------------
+     D--E--F--G--H
+    /     /
+A--B-----C
+------------------
+
+To rewrite only commits D,E,F,G,H, but leave A, B and C alone, use:
+
+--------------------------------
+git filter-branch ... new-H C..H
+--------------------------------
+
+To rewrite commits E,F,G,H, use one of these:
+
+----------------------------------------
+git filter-branch ... new-H C..H --not D
+git filter-branch ... new-H D..H --not C
+----------------------------------------
+
+To move the whole tree into a subdirectory, or remove it from there:
+
+---------------------------------------------------------------
+git filter-branch --index-filter \
+	'git ls-files -s | sed "s-\t-&newsubdir/-" |
+		GIT_INDEX_FILE=$GIT_INDEX_FILE.new \
+			git update-index --index-info &&
+	 mv $GIT_INDEX_FILE.new $GIT_INDEX_FILE' directorymoved
+---------------------------------------------------------------
+
+
+Author
+------
+Written by Petr "Pasky" Baudis <pasky@suse.cz>,
+and the git list <git@vger.kernel.org>
+
+Documentation
+--------------
+Documentation by Petr Baudis and the git list.
+
+GIT
+---
+Part of the gitlink:git[7] suite
diff --git a/git-filter-branch.sh b/git-filter-branch.sh
index 3772951..22fb5bf 100644
--- a/git-filter-branch.sh
+++ b/git-filter-branch.sh
@@ -4,190 +4,9 @@
 # Copyright (c) Petr Baudis, 2006
 # Minimal changes to "port" it to core-git (c) Johannes Schindelin, 2007
 #
-# Lets you rewrite GIT revision history by creating a new branch from
-# your current branch by applying custom filters on each revision.
-# Those filters can modify each tree (e.g. removing a file or running
-# a perl rewrite on all files) or information about each commit.
-# Otherwise, all information (including original commit times or merge
-# information) will be preserved.
-#
-# The command takes the new branch name as a mandatory argument and
-# the filters as optional arguments. If you specify no filters, the
-# commits will be recommitted without any changes, which would normally
-# have no effect and result with the new branch pointing to the same
-# branch as your current branch. (Nevertheless, this may be useful in
-# the future for compensating for some Git bugs or such, therefore
-# such a usage is permitted.)
-#
-# WARNING! The rewritten history will have different ids for all the
-# objects and will not converge with the original branch. You will not
-# be able to easily push and distribute the rewritten branch. Please do
-# not use this command if you do not know the full implications, and
-# avoid using it anyway - do not do what a simple single commit on top
-# of the current version would fix.
-#
-# Always verify that the rewritten version is correct before disposing
-# the original branch.
-#
-# Note that since this operation is extensively I/O expensive, it might
-# be a good idea to do it off-disk, e.g. on tmpfs. Reportedly the speedup
-# is very noticeable.
-#
-# OPTIONS
-# -------
-# -d TEMPDIR:: The path to the temporary tree used for rewriting
-#	When applying a tree filter, the command needs to temporary
-#	checkout the tree to some directory, which may consume
-#	considerable space in case of large projects. By default it
-#	does this in the '.git-rewrite/' directory but you can override
-#	that choice by this parameter.
-#
-# Filters
-# ~~~~~~~
-# The filters are applied in the order as listed below. The COMMAND
-# argument is always evaluated in shell using the 'eval' command.
-# The $GIT_COMMIT environment variable is permanently set to contain
-# the id of the commit being rewritten. The author/committer environment
-# variables are set before the first filter is run.
-#
-# A 'map' function is available that takes an "original sha1 id" argument
-# and outputs a "rewritten sha1 id" if the commit has been already
-# rewritten, fails otherwise; the 'map' function can return several
-# ids on separate lines if your commit filter emitted multiple commits
-# (see below).
-#
-# --env-filter COMMAND:: The filter for modifying environment
-#	This is the filter for modifying the environment in which
-#	the commit will be performed. Specifically, you might want
-#	to rewrite the author/committer name/email/time environment
-#	variables (see `git-commit` for details). Do not forget to
-#	re-export the variables.
-#
-# --tree-filter COMMAND:: The filter for rewriting tree (and its contents)
-#	This is the filter for rewriting the tree and its contents.
-#	The COMMAND argument is evaluated in shell with the working
-#	directory set to the root of the checked out tree. The new tree
-#	is then used as-is (new files are auto-added, disappeared files
-#	are auto-removed - .gitignore files nor any other ignore rules
-#	HAVE NO EFFECT!).
-#
-# --index-filter COMMAND:: The filter for rewriting index
-#	This is the filter for rewriting the Git's directory index.
-#	It is similar to the tree filter but does not check out the
-#	tree, which makes it much faster. However, you must use the
-#	lowlevel Git index manipulation commands to do your work.
-#
-# --parent-filter COMMAND:: The filter for rewriting parents
-#	This is the filter for rewriting the commit's parent list.
-#	It will receive the parent string on stdin and shall output
-#	the new parent string on stdout. The parent string is in
-#	format accepted by `git commit-tree`: empty for initial
-#	commit, "-p parent" for a normal commit and "-p parent1
-#	-p parent2 -p parent3 ..." for a merge commit.
-#
-# --msg-filter COMMAND:: The filter for rewriting commit message
-#	This is the filter for rewriting the commit messages.
-#	The COMMAND argument is evaluated in shell with the original
-#	commit message on standard input; its standard output is
-#	is used as the new commit message.
-#
-# --commit-filter COMMAND:: The filter for performing the commit
-#	If this filter is passed, it will be called instead of the
-#	`git commit-tree` command, with those arguments:
-#
-#		TREE_ID [-p PARENT_COMMIT_ID]...
-#
-#	and the log message on stdin. The commit id is expected on
-#	stdout. As a special extension, the commit filter may emit
-#	multiple commit ids; in that case, all of them will be used
-#	as parents instead of the original commit in further commits.
-#
-# --tag-name-filter COMMAND:: The filter for rewriting tag names.
-#	If this filter is passed, it will be called for every tag ref
-#	that points to a rewritten object (or to a tag object which
-#	points to a rewritten object). The original tag name is passed
-#	via standard input, and the new tag name is expected on standard
-#	output.
-#
-#	The original tags are not deleted, but can be overwritten;
-#	use "--tag-name-filter=cat" to simply update the tags. In this
-#	case, be very careful and make sure you have the old tags
-#	backed up in case the conversion has run afoul.
-#
-#	Note that there is currently no support for proper rewriting of
-#	tag objects; in layman terms, if the tag has a message or signature
-#	attached, the rewritten tag won't have it. Sorry. (It is by
-#	definition impossible to preserve signatures at any rate, though.)
-#
-# --subdirectory-filter DIRECTORY:: Only regard the history, as seen by
-#	the given subdirectory. The result will contain that directory as
-#	its project root.
-#
-# EXAMPLE USAGE
-# -------------
-# Suppose you want to remove a file (containing confidential information
-# or copyright violation) from all commits:
-#
-#	git-filter-branch --tree-filter 'rm filename' newbranch
-#
-# A significantly faster version:
-#
-#	git-filter-branch --index-filter 'git update-index --remove filename' newbranch
-#
-# Now, you will get the rewritten history saved in the branch 'newbranch'
-# (your current branch is left untouched).
-#
-# To "etch-graft" a commit to the revision history (set a commit to be
-# the parent of the current initial commit and propagate that):
-#
-#	git-filter-branch --parent-filter sed\ 's/^$/-p graftcommitid/' newbranch
-#
-# (if the parent string is empty - therefore we are dealing with the
-# initial commit - add graftcommit as a parent). Note that this assumes
-# history with a single root (that is, no git-merge without common ancestors
-# happened). If this is not the case, use:
-#
-#	git-filter-branch --parent-filter 'cat; [ "$GIT_COMMIT" = "COMMIT" ] && echo "-p GRAFTCOMMIT"' newbranch
-#
-# To remove commits authored by "Darl McBribe" from the history:
-#
-#	git-filter-branch --commit-filter 'if [ "$GIT_AUTHOR_NAME" = "Darl McBribe" ]; then shift; while [ -n "$1" ]; do shift; echo "$1"; shift; done; else git commit-tree "$@"; fi' newbranch
-#
-# (the shift magic first throws away the tree id and then the -p
-# parameters). Note that this handles merges properly! In case Darl
-# committed a merge between P1 and P2, it will be propagated properly
-# and all children of the merge will become merge commits with P1,P2
-# as their parents instead of the merge commit.
-#
-# To restrict rewriting to only part of the history, specify a revision
-# range in addition to the new branch name. The new branch name will
-# point to the top-most revision that a 'git rev-list' of this range
-# will print.
-#
-# Consider this history:
-#
-#	     D--E--F--G--H
-#	    /     /
-#	A--B-----C
-#
-# To rewrite commits D,E,F,G,H, use:
-#
-#	git-filter-branch ... new-H C..H
-#
-# To rewrite commits E,F,G,H, use one of these:
-#
-#	git-filter-branch ... new-H C..H --not D
-#	git-filter-branch ... new-H D..H --not C
-#
-# To move the whole tree into a subdirectory, or remove it from there:
-#
-# git-filter-branch --index-filter \
-#	'git ls-files -s | sed "s-\t-&newsubdir/-" |
-#		GIT_INDEX_FILE=$GIT_INDEX_FILE.new \
-#			git update-index --index-info &&
-#	 mv $GIT_INDEX_FILE.new $GIT_INDEX_FILE' directorymoved
-
-# Testsuite: TODO
+# Lets you rewrite the revision history of the current branch, creating
+# a new branch. You can specify a number of filters to modify the commits,
+# files and trees.
 
 set -e
 
-- 
1.5.3.rc0.2640.g59df9-dirty

^ permalink raw reply related

* [PATCH] Document -<n> for git-format-patch
From: Miklos Vajna @ 2007-07-03 23:38 UTC (permalink / raw)
  To: git, gitster

[-- Attachment #1: Type: text/plain, Size: 769 bytes --]

The -<n> option was not mentioned in git-format-patch's manpage till
now. Fix this.

Signed-off-by: Miklos Vajna <vmiklos@frugalware.org>
---

At least as far as I see. Correct me if I'm wrong :)

 Documentation/git-format-patch.txt |    3 +++
 1 files changed, 3 insertions(+), 0 deletions(-)

diff --git a/Documentation/git-format-patch.txt b/Documentation/git-format-patch.txt
index e563810..6cbcf93 100644
--- a/Documentation/git-format-patch.txt
+++ b/Documentation/git-format-patch.txt
@@ -53,6 +53,9 @@ OPTIONS
 -------
 include::diff-options.txt[]
 
+-<n>::
+	Limits the number of patches to prepare.
+
 -o|--output-directory <dir>::
 	Use <dir> to store the resulting files, instead of the
 	current working directory.
-- 
1.5.2.2


[-- Attachment #2: Type: application/pgp-signature, Size: 189 bytes --]

^ permalink raw reply related

* Re: [PATCH] Document git-filter-branch
From: Johannes Schindelin @ 2007-07-03 23:17 UTC (permalink / raw)
  To: Frank Lichtenheld; +Cc: git, gitster
In-Reply-To: <20070703220540.GN12721@planck.djpig.de>

Hi,

[if you comment on just a small portion of the text, could you please 
quote only that? Thank you]

On Wed, 4 Jul 2007, Frank Lichtenheld wrote:

> General note: All the stuff in all uppercase should probably also
> have some asciidoc emphasis.

I do not understand. I grepped through all the docs for uppercase words 
emphasized in any way, and could not find one.

> On Tue, Jul 03, 2007 at 05:47:44PM +0100, Johannes Schindelin wrote:
>
> > +Note that since this operation is extensively I/O expensive, it might
> > +be a good idea to redirect the temporary directory it off-disk, e.g. on
>                                                     ^^^^^^
> The "it" probably doesn't belong there.

Right.

> > +The filters are applied in the order as listed below.  The <command>
> > +argument is always evaluated in shell using the 'eval' command.
> > +The $GIT_COMMIT environment variable is permanently set to contain
>                                            ^^^^^^^^^^^
> I find the use of this word in this context odd and a little confusing.
> Maybe better "always" or "each time"?

How about

	Prior to that, the $GIT_COMMIT environment variable will be set to 
	contain the id of the commit being rewritten.

> > +the id of the commit being rewritten.  The author/committer environment
> > +variables are set before the first filter is run.
> 
> Maybe give the actual names of the environment variables here?

If you think so:

	Also, GIT_AUTHOR_NAME, GIT_AUTHOR_EMAIL, GIT_AUTHOR_DATE, 
	GIT_COMMITTER_NAME, GIT_COMMITTER_EMAIL, and GIT_COMMITTER_DATE is 
	set according to the current commit.

> > +	is then used as-is (new files are auto-added, disappeared files
> > +	are auto-removed - .gitignore files nor any other ignore rules
> > +	HAVE NO EFFECT!).
> 
> Is "nor" correct here? Not just "or"?

Do you like

	neither .gitignore files nor any other ignore rules HAVE ANY 
	EFFECT!

> [...]
> > +--subdirectory-filter <directory>::
> > +	Only regard the history, as seen by the given subdirectory. The
>                               ^^^
> Does this comma belong there?

This is my bad English. What I meant was this:

        Only ever look at the history, which touches the given 
	subdirectory.  The result will contain that directory as its 
	project root.

> > +-------------------------------------------------------------------------------
> > +git filter-branch --index-filter 'git update-index --remove filename' newbranch
> > +-------------------------------------------------------------------------------
> 
> Even if your code goes beyond 80 chars, the surrounding "---" doesn't
> have to and makes it even harder to read when reading the original
> asciidoc text.

I personally read the .txt files, and use asciidoc only when I am forced 
to. So it makes a difference for me.

> > +----------------------------------------------------------------------
> > +git filter-branch --parent-filter sed\ 's/^$/-p <graft-id>/' newbranch
> > +----------------------------------------------------------------------
> 
> Wouldn't have 'sed s/^$/-p <graft-id>/' exactly the same effect, since
> the quotes are interpreted by the original shell anyway and not the
> filter shell? Just wondering why it uses such a complicated way to
> express it.

Probably not. Since the shell would interpret "s/^$/-p" and "<graft-id>/" 
as two arguments to sed.

Besides, like Pasky, I am used to quote the argument, and not the whole 
line, that's why the line is still there as it is.

Thanks,
Dscho

^ permalink raw reply

* [PATCH] gitk: fix for "gitk <ambiguous-name> --"
From: Johannes Schindelin @ 2007-07-03 22:55 UTC (permalink / raw)
  To: Paul Mackerras; +Cc: Linus Torvalds, Uwe Kleine-K?nig, git
In-Reply-To: <alpine.LFD.0.98.0707031514160.9434@woody.linux-foundation.org>

[-- Attachment #1: Type: TEXT/PLAIN, Size: 1064 bytes --]


If you have an ambiguous ref, i.e. a file in the working directory bears
the same name, you have to use "--" at the end to disambiguate ref from
file. This works with "git rev-list". Make it work with gitk, too.

Noticed by Uwe Kleine-König.

Signed-off-by: Johannes Schindelin <johannes.schindelin@gmx.de>
---

	Uwe, did your name come out right? I recently had to manually fix 
	pine, and realised only then what a tedious work it is to teach 
	pine about utf-8. Hopefully it worked out.

 gitk |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/gitk b/gitk
index 2d6a6ef..a248f5a 100755
--- a/gitk
+++ b/gitk
@@ -7440,7 +7440,7 @@ set cmdline_files {}
 set i [lsearch -exact $revtreeargs "--"]
 if {$i >= 0} {
     set cmdline_files [lrange $revtreeargs [expr {$i + 1}] end]
-    set revtreeargs [lrange $revtreeargs 0 [expr {$i - 1}]]
+    set revtreeargs [lrange $revtreeargs 0 $i]
 } elseif {$revtreeargs ne {}} {
     if {[catch {
 	set f [eval exec git rev-parse --no-revs --no-flags $revtreeargs]
-- 
1.5.3.rc0.2640.g59df9-dirty


^ permalink raw reply related

* [PATCH] git-init: set core.worktree if GIT_WORK_TREE is specified
From: Matthias Lederhofer @ 2007-07-03 22:49 UTC (permalink / raw)
  To: git

Now you can do the following to create a repository which
has a separate working tree:

    /tmp/foo$ export GIT_DIR=/tmp/bar
    /tmp/foo$ git --work-tree . init
    Initialized empty Git repository in /tmp/bar/
    /tmp/foo$ git config core.worktree
    /tmp/foo

Signed-off-by: Matthias Lederhofer <matled@gmx.net>
---
Without this I found it quite complicated to create a non bare
repository which is not in a .git directory.

Some stuff I was wondering about while writing this patch:

 * Should we have a function similar to err(3) which prints
   ": " and strerror(errno) after the supplied error message?
   This function could be used instead of die whenever errno contains
   some meaningful value.

 * Should git init create the whole path to the repository and not
   only the last component?  I.e. git --git-dir /tmp/a init suceeds
   but git --git-dir /tmp/a/b/c init fails (unless /tmp/a/b exists).

 * Should git init create the working tree if it does not exist?

 * Is this something which should have a test?  git init doesn't seem
   to have any tests yet beside basic tests if the created repository
   looks ok.
---
 builtin-init-db.c |   40 +++++++++++++++++++++++++++++++++++++---
 1 files changed, 37 insertions(+), 3 deletions(-)

diff --git a/builtin-init-db.c b/builtin-init-db.c
index 976f47b..ff5c13b 100644
--- a/builtin-init-db.c
+++ b/builtin-init-db.c
@@ -174,7 +174,36 @@ static void copy_templates(const char *git_dir, int len, const char *template_di
 	closedir(dir);
 }
 
-static int create_default_files(const char *git_dir, const char *template_path)
+/*
+ * Get the full path to the working tree specified in $GIT_WORK_TREE
+ * or NULL if no working tree is specified.
+ */
+static const char *get_work_tree(void)
+{
+	const char *git_work_tree;
+	char cwd[PATH_MAX];
+	static char worktree[PATH_MAX];
+
+	git_work_tree = getenv(GIT_WORK_TREE_ENVIRONMENT);
+	if (!git_work_tree)
+		return NULL;
+	if (!getcwd(cwd, sizeof(cwd)) || cwd[0] != '/')
+		die("Unable to read current working directory");
+	if (chdir(git_work_tree))
+		die("Cannot change directory to specified working tree '%s'",
+			git_work_tree);
+	if (git_work_tree[0] != '/') {
+		if (!getcwd(worktree, sizeof(worktree)) || worktree[0] != '/')
+			die("Unable to read current working directory");
+		git_work_tree = worktree;
+	}
+	if (chdir(cwd))
+		die("Cannot come back to cwd");
+	return git_work_tree;
+}
+
+static int create_default_files(const char *git_dir, const char *git_work_tree,
+	const char *template_path)
 {
 	unsigned len = strlen(git_dir);
 	static char path[PATH_MAX];
@@ -253,7 +282,7 @@ static int create_default_files(const char *git_dir, const char *template_path)
 	}
 	git_config_set("core.filemode", filemode ? "true" : "false");
 
-	if (is_bare_repository()) {
+	if (is_bare_repository() && !git_work_tree) {
 		git_config_set("core.bare", "true");
 	}
 	else {
@@ -261,6 +290,8 @@ static int create_default_files(const char *git_dir, const char *template_path)
 		/* allow template config file to override the default */
 		if (log_all_ref_updates == -1)
 		    git_config_set("core.logallrefupdates", "true");
+		if (git_work_tree)
+			git_config_set("core.worktree", git_work_tree);
 	}
 	return reinit;
 }
@@ -277,6 +308,7 @@ static const char init_db_usage[] =
 int cmd_init_db(int argc, const char **argv, const char *prefix)
 {
 	const char *git_dir;
+	const char *git_work_tree;
 	const char *sha1_dir;
 	const char *template_dir = NULL;
 	char *path;
@@ -294,6 +326,8 @@ int cmd_init_db(int argc, const char **argv, const char *prefix)
 			usage(init_db_usage);
 	}
 
+	git_work_tree = get_work_tree();
+
 	/*
 	 * Set up the default .git directory contents
 	 */
@@ -309,7 +343,7 @@ int cmd_init_db(int argc, const char **argv, const char *prefix)
 	 */
 	check_repository_format();
 
-	reinit = create_default_files(git_dir, template_dir);
+	reinit = create_default_files(git_dir, git_work_tree, template_dir);
 
 	/*
 	 * And set up the object store.
-- 
1.5.2.2.646.g71e55-dirty

^ permalink raw reply related

* Re: [BUG] gitk fails with argument that is both existing directory and branch name
From: Johannes Schindelin @ 2007-07-03 22:44 UTC (permalink / raw)
  To: Linus Torvalds; +Cc: Uwe Kleine-K?nig, git
In-Reply-To: <alpine.LFD.0.98.0707031514160.9434@woody.linux-foundation.org>

Hi,

On Tue, 3 Jul 2007, Linus Torvalds wrote:

> On Tue, 3 Jul 2007, Johannes Schindelin wrote:
> 
> > Umm. Why don't you just use gitk linus/master..fixes? This is how we 
> > teach people to use rev-list anyway.
> 
> No, Uwe is right. There's a bug somewhere.

I never questioned that there is a bug. I was only wondering why he used 
that ambiguous way to specify a range, when a range is clearly what he 
wants.

Ah well. I'll look into it.

Ciao,
Dscho

^ permalink raw reply

* [PATCH] gitweb: prefer git_get_project_owner() over get_file_owner()
From: Miklos Vajna @ 2007-07-03 22:11 UTC (permalink / raw)
  To: git; +Cc: gitster
In-Reply-To: <11834866911868-git-send-email-vmiklos@frugalware.org>

This way if $projects_list exists, it'll be used, otherwise get_file_owner()
will be used as before.

Signed-off-by: Miklos Vajna <vmiklos@frugalware.org>
---

Sorry for sending it again, even if sending it to myself first, the long
description was left out somehow.

Also it seems that i had some problem with git-send-email, my bad.

 gitweb/gitweb.perl |    4 ++--
 1 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/gitweb/gitweb.perl b/gitweb/gitweb.perl
index dbfb044..6201b90 100755
--- a/gitweb/gitweb.perl
+++ b/gitweb/gitweb.perl
@@ -3166,7 +3166,7 @@ sub git_project_list_body {
 			$pr->{'descr'} = chop_str($descr, 25, 5);
 		}
 		if (!defined $pr->{'owner'}) {
-			$pr->{'owner'} = get_file_owner("$projectroot/$pr->{'path'}") || "";
+			$pr->{'owner'} = git_get_project_owner("$pr->{'path'}") || "";
 		}
 		if ($check_forks) {
 			my $pname = $pr->{'path'};
@@ -3590,7 +3590,7 @@ sub git_project_index {
 
 	foreach my $pr (@projects) {
 		if (!exists $pr->{'owner'}) {
-			$pr->{'owner'} = get_file_owner("$projectroot/$pr->{'path'}");
+			$pr->{'owner'} = git_get_project_owner("$pr->{'path'}");
 		}
 
 		my ($path, $owner) = ($pr->{'path'}, $pr->{'owner'});
-- 
1.5.2.2

^ permalink raw reply related

* Re: Problems with git-svnimport
From: Peter Baumann @ 2007-07-03 22:19 UTC (permalink / raw)
  To: Matthias Urlichs; +Cc: git
In-Reply-To: <loom.20070703T214211-88@post.gmane.org>

On Tue, Jul 03, 2007 at 07:45:12PM +0000, Matthias Urlichs wrote:
> Johannes Schindelin <Johannes.Schindelin <at> gmx.de> writes:
> 
> > Let's deprecate git-svnimport, once for all.
> > 
> > git-svn should work much better.
> > 
> In other words, you volunteer to fold everything that git-svnimport can do into
> git-svn? The last time I checked, neither was a feature-complete subset of the
> other...
> 
> If so: don't let me hold you back. ;-)
> 

May I ask what is missing in git-svn to replace git-svnimport? As I
can't think of anything which is missing in git-svn.

-Peter

^ permalink raw reply

* Re: [BUG] gitk fails with argument that is both existing directory and branch name
From: Linus Torvalds @ 2007-07-03 22:17 UTC (permalink / raw)
  To: Johannes Schindelin; +Cc: Uwe Kleine-K?nig, git
In-Reply-To: <Pine.LNX.4.64.0707032248570.4071@racer.site>



On Tue, 3 Jul 2007, Johannes Schindelin wrote:
> 
> Umm. Why don't you just use gitk linus/master..fixes? This is how we teach 
> people to use rev-list anyway.

No, Uwe is right. There's a bug somewhere.

This _should_ work:

	# create a fake 'gitk' branch if you don't have one already
	git branch gitk master

	# This should look at the 'gitk' branch
	gitk gitk --

but it doesn't. It just hangs for me.

It seems to be some fairly recent gitk bug, too, because I'm pretty sure 
it _used_ to work.

I checked, and "git rev-list" works fine:

	git rev-list --default HEAD gitk

fails correctly with

	fatal: ambiguous argument 'gitk': both revision and filename
	Use '--' to separate filenames from revisions

and the way to get it to work as a branch-name is to do

	git rev-list --default HEAD gitk --

which works fine.

			Linus

^ permalink raw reply

* Re: Starting 1.5.3 stabilization cycle
From: Peter Baumann @ 2007-07-03 22:16 UTC (permalink / raw)
  To: Johannes Schindelin; +Cc: Junio C Hamano, git
In-Reply-To: <Pine.LNX.4.64.0707031923180.4071@racer.site>

On Tue, Jul 03, 2007 at 07:27:54PM +0100, Johannes Schindelin wrote:

[... skipping an embarrassing part of the message :-) ...]

> > 	This is meant for reordering the commits, merge several commits into
> > 	one or even remove some of them.
> 
> Or even better:
> 
> 	- "git rebase" learned an "interactive" mode, where you can pick 
> 	  and reorder the commits to be applied.

Sounds nicer, but I would add that it is also possible to remove commits.

> > >   - "git-filter-branch" is a reborn cg-admin-rewritehist.
> > 
> > Better mention what it is for, e.g:
> > 
> > 	Lets you rewrite GIT revision history by applying custom filters 
> >	on each revision. Those filters can modify each tree or 
> >	information about each commit.
> 
> I never liked that description. How about (shameless plug) the description 
> >from my last patch:
> 
> 	git-filter-branch lets you rewrite the revision history of the 
> 	current branch, creating a new branch. You can specify a number of 
> 	filters to modify the commits, files and trees.

I find it a little distracting to mention the "new branch" in this short
description. I think this belongs into the manpage and not in a short
description for the release notes. But I agree that this sounds otherwise nicer.

-Peter

^ permalink raw reply


This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox