Commit Graph

4001 Commits

Author SHA1 Message Date
Eric Wong
8f22562c6b contrib/git-svn: add show-ignore command
Recursively finds and lists the svn:ignore property on
directories.  The output is suitable for appending to the
$GIT_DIR/info/exclude file.

Signed-off-by: Eric Wong <normalperson@yhbt.net>
Signed-off-by: Junio C Hamano <junkio@cox.net>
2006-02-26 14:55:13 -08:00
Ryan Anderson
f60d46911d annotate: Use qx{} for pipes on activestate.
Note: This needs someone to tell me what the value of $^O is on ActiveState.

Signed-off-by: Ryan Anderson <ryan@michonline.com>
Signed-off-by: Junio C Hamano <junkio@cox.net>
2006-02-26 14:45:22 -08:00
Ryan Anderson
6b3e21d603 annotate: Convert all -| calls to use a helper open_pipe().
When we settle on a solution for ActiveState's forking issues, all
compatibility checks can be handled inside this one function.

Also, fixed an abuse of global variables in the process of cleaning this up.

Signed-off-by: Ryan Anderson <ryan@michonline.com>
Signed-off-by: Junio C Hamano <junkio@cox.net>
2006-02-26 14:45:05 -08:00
Ryan Anderson
87475f4dfc annotate: Handle dirty state and arbitrary revisions.
Also, use Getopt::Long and only process each rev once.

(Thanks to Morten Welinder for spotting the performance problems.)

Signed-off-by: Ryan Anderson <ryan@michonline.com>
Signed-off-by: Junio C Hamano <junkio@cox.net>
2006-02-26 14:43:55 -08:00
Lukas Sandström
9d7f73d43f git-fetch: print the new and old ref when fast-forwarding
Signed-off-by: Lukas Sandström <lukass@etek.chalmers.se>
Signed-off-by: Junio C Hamano <junkio@cox.net>
2006-02-25 12:03:18 -08:00
Junio C Hamano
ab57c8dd2a Merge branch 'master' into next
* master:
  fix warning from pack-objects.c
  Merge branches 'jc/rev-list' and 'jc/pack-thin'
  gitview: Fix the graph display .
2006-02-24 23:47:48 -08:00
Luck, Tony
8fcf1ad9c6 fix warning from pack-objects.c
When compiling on ia64 I get this warning (from gcc 3.4.3):

gcc -o pack-objects.o -c -g -O2 -Wall -DSHA1_HEADER='<openssl/sha.h>'  pack-objects.c
pack-objects.c: In function `pack_revindex_ix':
pack-objects.c:94: warning: cast from pointer to integer of different size

A double cast (first to long, then to int) shuts gcc up, but is there
a better way?

[jc: Andreas Ericsson suggests to use ulong instead. ]

Signed-off-by: Tony Luck <tony.luck@intel.com>
Signed-off-by: Junio C Hamano <junkio@cox.net>
2006-02-24 22:17:20 -08:00
Junio C Hamano
f0b0af1b04 Merge branches 'jc/rev-list' and 'jc/pack-thin'
* jc/rev-list:
  rev-list --objects: use full pathname to help hashing.
  rev-list --objects-edge: remove duplicated edge commit output.
  rev-list --objects-edge

* jc/pack-thin:
  pack-objects: hash basename and direname a bit differently.
  pack-objects: allow "thin" packs to exceed depth limits
  pack-objects: use full pathname to help hashing with "thin" pack.
  pack-objects: thin pack micro-optimization.
  Use thin pack transfer in "git fetch".
  Add git-push --thin.
  send-pack --thin: use "thin pack" delta transfer.
  Thin pack - create packfile with missing delta base.

Conflicts:

	pack-objects.c (taking "next")
	send-pack.c (taking "next")
2006-02-24 21:55:23 -08:00
Junio C Hamano
d55e0fff1f Merge branch 'master' into next
* master:
  Merge branches 'jc/rev-list' and 'jc/pack-thin'
  gitview: Code cleanup
  Add missing programs to ignore list
  git ls files recursively show ignored files
  Build and install git-mailinfo.
  gitview: Bump the rev
  gitview: Fix DeprecationWarning
2006-02-24 19:01:02 -08:00
Junio C Hamano
52e8a6e9bf Merge branches 'jc/rev-list' and 'jc/pack-thin'
* jc/rev-list:
  rev-list --objects: use full pathname to help hashing.
  rev-list --objects-edge: remove duplicated edge commit output.
  rev-list --objects-edge

* jc/pack-thin:
  pack-objects: hash basename and direname a bit differently.
  pack-objects: allow "thin" packs to exceed depth limits
  pack-objects: use full pathname to help hashing with "thin" pack.
  pack-objects: thin pack micro-optimization.
  Use thin pack transfer in "git fetch".
  Add git-push --thin.
  send-pack --thin: use "thin pack" delta transfer.
  Thin pack - create packfile with missing delta base.

Conflicts:

	pack-objects.c (manual adjustment for thin pack needed)
	send-pack.c
2006-02-24 18:55:25 -08:00
Aneesh Kumar K.V
1509bd9e69 gitview: Fix the graph display .
This fix all the known issue with the graph display
The bug need to be explained graphically

                                 |
                                 a
This line need not be there ---->| \
                                 b  |
                                 | /
                                 c

c is parent of a and all a,b and c are placed on the same line and b is child of c
With my last checkin I added  a seperate line to indicate that a is
connected to c. But then we had the line connecting a and b which should
not be ther. This changes fixes the same bug

Signed-off-by: Aneesh Kumar K.V <aneesh.kumar@gmail.com>
Signed-off-by: Junio C Hamano <junkio@cox.net>
2006-02-24 17:27:46 -08:00
Aneesh Kumar K.V
9e4f522da7 gitview: Code cleanup
Rearrange the code little bit so that it is easier to read

Signed-off-by: Aneesh Kumar K.V <aneesh.kumar@gmail.com>
Signed-off-by: Junio C Hamano <junkio@cox.net>
2006-02-24 17:27:39 -08:00
Shawn Pearce
6ee9240f63 Add missing programs to ignore list
Added recently added programs to the default exclude list.

Signed-off-by: Junio C Hamano <junkio@cox.net>
2006-02-24 16:16:39 -08:00
Shawn Pearce
1e3584053d git ls files recursively show ignored files
Make git-ls-files --others --ignored recurse into non-excluded
subdirectories.

Typically when asking git-ls-files to display all files which are
ignored by one or more exclude patterns one would want it to recurse
into subdirectories which are not themselves excluded to see if
there are any excluded files contained within those subdirectories.

Signed-off-by: Junio C Hamano <junkio@cox.net>
2006-02-24 16:16:34 -08:00
Junio C Hamano
43f72af1bc Build and install git-mailinfo.
The merge 712b1dd389 was done
incorrectly, and lost this program from Makefile.

Big thanks go to Tony Luck for noticing it, and Linus for
diagnosing it.

Signed-off-by: Junio C Hamano <junkio@cox.net>
2006-02-24 16:16:10 -08:00
Aneesh Kumar
20d23f554d gitview: Bump the rev
Make the 0.7 release

Signed-off-by: Aneesh Kumar K.V <aneesh.kumar@gmail.com>
Signed-off-by: Junio C Hamano <junkio@cox.net>
2006-02-24 03:14:44 -08:00
Aneesh Kumar
8b42f5ae54 gitview: Fix DeprecationWarning
DeprecationWarning: integer argument expected, got float

Signed-off-by: Aneesh Kumar K.V <aneesh.kumar@gmail.com>
Signed-off-by: Junio C Hamano <junkio@cox.net>
2006-02-24 03:14:34 -08:00
Junio C Hamano
1b1ad31aa8 Merge branch 'master' into next
* master:
  Merge fixes early for next maint series.
  Merge branch 'fix' into maint
  git-am: do not allow empty commits by mistake.
2006-02-24 02:22:01 -08:00
Junio C Hamano
a68de9592e Merge fixes early for next maint series. 2006-02-24 02:21:28 -08:00
Junio C Hamano
6d5129ac09 Merge branch 'fix' into maint
* fix:
  git-am: do not allow empty commits by mistake.
2006-02-24 02:21:00 -08:00
Junio C Hamano
7465ef5155 Merge branches 'jc/rev-list' and 'jc/pack-thin' into next
* jc/rev-list:
  rev-list --objects: use full pathname to help hashing.

* jc/pack-thin:
  pack-objects: hash basename and direname a bit differently.
  pack-objects: allow "thin" packs to exceed depth limits
  pack-objects: use full pathname to help hashing with "thin" pack.
2006-02-24 01:56:38 -08:00
Junio C Hamano
4b953cdc04 Merge fix bits from jc/rev-list 2006-02-24 01:33:57 -08:00
Junio C Hamano
5ca5396c9e Merge branch 'np/delta' into next
* np/delta:
  Revert "diff-delta: produce optimal pack data"
  Tweak break/merge score to adjust to the new delta generation code.
  count-delta: fix counting of copied source.
2006-02-24 01:30:04 -08:00
Junio C Hamano
eae3fe5e50 Revert "diff-delta: produce optimal pack data"
This reverts 6b7d25d97b commit.

It turns out that the new algorithm has a really bad corner
case, that literally spends minutes for inputs that takes less
than a quater seconds to delta with the old algorithm.  The
resulting delta is 50% smaller which is admirable, but the
performance degradation is simply unacceptable for unconditional
use.

Some example cases are these blobs in Linux 2.6 repository:

    4917ec509720a42846d513addc11cbd25e0e3c4f
    9af06ba723df75fed49f7ccae5b6c9c34bc5115f
    dfc9cd58dc065d17030d875d3fea6e7862ede143

Signed-off-by: Junio C Hamano <junkio@cox.net>
2006-02-24 01:29:00 -08:00
Junio C Hamano
e6a933bdb7 Merge fixes from master 2006-02-24 01:14:41 -08:00
Junio C Hamano
eeef7135fe pack-objects: hash basename and direname a bit differently.
...so that "Makefile"s from different revs are sorted together,
separate from "t/Makefile"s, but close enough.

Signed-off-by: Junio C Hamano <junkio@cox.net>
2006-02-23 23:51:01 -08:00
Junio C Hamano
e646de0d14 rev-list --objects: use full pathname to help hashing.
This helps to group the same files from different revs together,
while spreading files with the same basename in different
directories, to help pack-object.

Signed-off-by: Junio C Hamano <junkio@cox.net>
2006-02-23 23:44:42 -08:00
Junio C Hamano
eb38cc689e rev-list --objects-edge: remove duplicated edge commit output.
Signed-off-by: Junio C Hamano <junkio@cox.net>
2006-02-23 23:44:15 -08:00
Junio C Hamano
b76f6b6278 pack-objects: allow "thin" packs to exceed depth limits
When creating a new pack to be used in .git/objects/pack/
directory, we carefully count the depth of deltified objects to
be reused, so that the generated pack does not to exceed the
specified depth limit for runtime efficiency.  However, when we
are generating a thin pack that does not contain base objects,
such a pack can only be used during network transfer that is
expanded on the other end upon reception, so being careful and
artificially cutting the delta chain does not buy us anything
except increased bandwidth requirement.  This patch disables the
delta chain depth limit check when reusing an existing delta.

Signed-off-by: Junio C Hamano <junkio@cox.net>
2006-02-23 23:04:52 -08:00
Junio C Hamano
3efaa937a5 Merge branch 'ar/win'
* ar/win:
  PATCH: simplify calls to git programs in git-fmt-merge-msg
2006-02-23 22:35:55 -08:00
Junio C Hamano
aa01568dc7 Merge branch 'jc/send-insane-refs'
* jc/send-insane-refs:
  send-pack: do not give up when remote has insanely large number of refs.
2006-02-23 22:34:39 -08:00
Junio C Hamano
816c02ce8e Merge fixes early for next maint series. 2006-02-23 22:27:03 -08:00
Junio C Hamano
7bd1527d2d Merge branches 'jc/fix-co-candy', 'jc/fix-rename-leak' and 'ar/fix-win' into maint
* jc/fix-co-candy:
  checkout - eye candy.

* jc/fix-rename-leak:
  diffcore-rename: plug memory leak.

* ar/fix-win:
  fix t5600-clone-fail-cleanup.sh on windows
2006-02-23 22:25:32 -08:00
Junio C Hamano
1d3d03bbea Merge branch 'ak/gitview'
* ak/gitview:
  gitview: Display the lines joining commit nodes clearly.
2006-02-23 22:20:30 -08:00
Aneesh Kumar K.V
3fe5489a25 gitview: Display the lines joining commit nodes clearly.
Since i wanted to limit the graph box size i was resetting
the window after an index of 5. This result in line joining
commit nodes to pass over nodes which are not related. The
changes fixes the same

Signed-off-by: Aneesh Kumar K.V <aneesh.kumar@gmail.com>
Signed-off-by: Junio C Hamano <junkio@cox.net>
2006-02-23 22:17:42 -08:00
Junio C Hamano
6d28644d69 git-am: do not allow empty commits by mistake.
Running "git-am --resolved" without doing anything can create an empty
commit. Prevent it.

Thanks for Eric W. Biederman for spotting this.

Signed-off-by: Junio C Hamano <junkio@cox.net>
2006-02-23 22:14:47 -08:00
Junio C Hamano
581845f0b8 Tweak break/merge score to adjust to the new delta generation code.
This lowers the default merge threshold score to 75% from
earlier 80%.  The break threshold stays the same at 50% for now,
but we might want to revisit it (and the rename detection limit
as well).

 * break score: this much edit (both insertion of new material
   and deletion of old material) needs to be there in the file
   before we consider this _might_ be a rewrite and break the
   filepair.

 * merge score: after a filepair is broken by the above criteria
   and goes through rename detection, if their pieces did not
   match with other files as rename/copy, we merge them back
   into one as if nothing happened.  If the filepair had at
   least this much deletion of old material, however, we say
   this is completely rewritten with dissimilarity index X% when
   we do so.

The updated delta code by Nico is so good that what we earlier
thought to be complete rewrite now reuses a lot more from the
source material (reducing the counted "delete"), so this
adjustment is needed to keep the perceived behaviour similar to
what we had earlier.

Signed-off-by: Junio C Hamano <junkio@cox.net>
2006-02-23 17:03:37 -08:00
Junio C Hamano
c86e8568d8 count-delta: fix counting of copied source.
The previous one wrongly coalesced a span with the next one
even though the span being added does not reach it.

Signed-off-by: Junio C Hamano <junkio@cox.net>
2006-02-23 15:50:18 -08:00
Alex Riesen
a92c73eccc PATCH: simplify calls to git programs in git-fmt-merge-msg
It also makes it work on ActiveState Perl.

Signed-off-by: Junio C Hamano <junkio@cox.net>
2006-02-23 03:49:09 -08:00
Alex Riesen
edd3ebfe27 fix t5600-clone-fail-cleanup.sh on windows
In windows you cannot remove current or opened directory,
an opened file, a running program, a loaded library, etc...

[jc: signoffs?  With a minor quoting fix.]

Signed-off-by: Junio C Hamano <junkio@cox.net>
2006-02-23 03:47:15 -08:00
Junio C Hamano
207a1f3ce9 Merge part of pack-thin branch 2006-02-23 03:00:59 -08:00
Junio C Hamano
d2540f0203 Merge branch 'np/delta' into next
* np/delta:
  count-delta: tweak counting of copied source material.
  diff-delta: produce optimal pack data
2006-02-23 02:59:24 -08:00
Junio C Hamano
907380eeff count-delta: tweak counting of copied source material.
With the finer grained delta algorithm, count-delta algorithm
started overcounting copied source material, since the new delta
output tends to reuse the same source range more than once and
more aggressively.  This broke an earlier assumption that the
number of bytes copied out from the source buffer is a good
approximation how much source material is actually remaining in
the result.

This uses fairly inefficient algorithm to keep track of ranges
of source material that are actually copied out to the
destination buffer.  With this tweak, the obvious rename/break
detection tests in the testsuite start to work again.

Signed-off-by: Junio C Hamano <junkio@cox.net>
2006-02-23 02:58:37 -08:00
Junio C Hamano
1d6b38cc76 pack-objects: use full pathname to help hashing with "thin" pack.
This uses the same hashing algorithm to the "preferred base
tree" objects and the incoming pathnames, to group the same
files from different revs together, while spreading files with
the same basename in different directories.

Signed-off-by: Junio C Hamano <junkio@cox.net>
2006-02-22 23:07:20 -08:00
Junio C Hamano
b925410d10 pack-objects: thin pack micro-optimization.
Since we sort objects by type, hash, preferredness and then
size, after we have a delta against preferred base, there is no
point trying a delta with non-preferred base.  This seems to
save expensive calls to diff-delta and it also seems to save the
output space as well.

Signed-off-by: Junio C Hamano <junkio@cox.net>
2006-02-22 21:45:45 -08:00
Junio C Hamano
63c2fcefd8 Merge branches 'maint', 'jc/fix-co-candy' and 'jc/fix-rename-leak' into next
* maint:
  Give no terminating LF to error() function.

* jc/fix-co-candy:
  checkout - eye candy.

* jc/fix-rename-leak:
  diffcore-rename: plug memory leak.
2006-02-22 19:46:59 -08:00
Junio C Hamano
09a5d72d8e diffcore-rename: plug memory leak.
Spotted by Nicolas Pitre.

Signed-off-by: Junio C Hamano <junkio@cox.net>
2006-02-22 19:45:48 -08:00
Junio C Hamano
98214e96be Merge branch 'ml/cvs'
* ml/cvs:
  Introducing git-cvsserver -- a CVS emulator for git.
2006-02-22 19:20:55 -08:00
Junio C Hamano
ab8c9fe256 Merge branch 'ra/anno'
* ra/anno:
  Use Ryan's git-annotate instead of jsannotate
  Add git-annotate, a tool for assigning blame.
2006-02-22 19:20:08 -08:00
Junio C Hamano
bd2afde8a3 Give no terminating LF to error() function.
Signed-off-by: Junio C Hamano <junkio@cox.net>
2006-02-22 19:10:26 -08:00