summaryrefslogtreecommitdiff
AgeCommit message (Collapse)Author
2006-05-14Add "--branches", "--tags" and "--remotes" options to git-rev-parse.Sean
"git branch" uses "rev-parse --all" and becomes much too slow when there are many tags (it scans all refs). Use the new "--branches" option of rev-parse to speed things up. Signed-off-by: Sean Estabrooks <seanlkml@sympatico.ca> Signed-off-by: Junio C Hamano <junkio@cox.net>
2006-05-14Merge branch 'fix'Junio C Hamano
* fix: include header to define uint32_t, necessary on Mac OS X
2006-05-14Merge branch 'fix' into maintJunio C Hamano
* fix: include header to define uint32_t, necessary on Mac OS X
2006-05-14include header to define uint32_t, necessary on Mac OS XBen Clifford
Signed-off-by: Junio C Hamano <junkio@cox.net>
2006-05-14Merge branch 'ml/cvs'Junio C Hamano
* ml/cvs: Change to allow subdir updates from Eclipse Many fixes for most operations in Eclipse. Added logged warnings for CVS error returns cvsserver: use git-rev-list instead of git-log git-cvsexportcommit: Add -f(orce) and -m(essage prefix) flags, small cleanups.
2006-05-14Merge branch 'fix'Junio C Hamano
* fix: Fix git-pack-objects for 64-bit platforms
2006-05-13Merge branch 'lt/fix-config' into lt/configJunio C Hamano
* lt/fix-config: git config syntax updates Another config file parsing fix. checkout: use --aggressive when running a 3-way merge (-m). Fix git-pack-objects for 64-bit platforms with manual adjustment of t/t1300 for "git repo-config --list" option. Signed-off-by: Junio C Hamano <junkio@cox.net>
2006-05-13git config syntax updatesLinus Torvalds
This updates the hierarchical section name syntax to [section<space>+"<randomstring>"] where the only rule for "randomstring" is that it can't contain a newline, and if you really want to insert a double-quote, you do it with \". It turns that into the section name "secion.randomstring". The "section" part is still case insensitive, but the "randomstring" part is case sensitive. So you could use this for things like [email "torvalds@osdl.org"] name = Linus Torvalds if you wanted to do the "email->name" conversion as part of the config file format (I'm not claiming that is sensible, I'm just giving it as an insane example). That would show up as the association email.torvalds@osdl.org.name -> Linus Torvalds which is easy to parse (the "." in the email _looks_ ambiguous, but it isn't: you know that there will always be a single key-name, so you find the key name with "strrchr(name, '.')" and things are entirely unambiguous). Repo-config is updated to be able to parse the new format, and also write things out in the new format. [jc: rolled two patches from Linus and one fix-up from Sean into one, with additional adjustments for t/t1300 test to check the case insensitiveness of section base and variable and case sensitiveness of the extended section part. Then stripped some part off to make the result applicable to the stale 1.3.X series that does not have recent enhancements. ] Signed-off-by: Linus Torvalds <torvalds@osdl.org> Signed-off-by: Sean Estabrooks <seanlkml@sympatico.ca> Signed-off-by: Junio C Hamano <junkio@cox.net>
2006-05-13Another config file parsing fix.sean
If the variable we need to store should go into a section that currently only has a single variable (not matching the one we're trying to insert), we will already be into the next section before we notice we've bypassed the correct location to insert the variable. To handle this case we store the current location as soon as we find a variable matching the section of our new variable. This breakage was brought up by Linus. Signed-off-by: Sean Estabrooks <seanlkml@sympatico.ca> Signed-off-by: Junio C Hamano <junkio@cox.net>
2006-05-13checkout: use --aggressive when running a 3-way merge (-m).Junio C Hamano
After doing an in-index 3-way merge, we always do the stock "merge-index merge-one-file" without doing anything fancy; use of --aggressive helps performance quite a bit. Signed-off-by: Junio C Hamano <junkio@cox.net>
2006-05-13Fix git-pack-objects for 64-bit platformsDennis Stosberg
The offset of an object in the pack is recorded as a 4-byte integer in the index file. When reading the offset from the mmap'ed index in prepare_pack_revindex(), the address is dereferenced as a long*. This works fine as long as the long type is four bytes wide. On NetBSD/sparc64, however, a long is 8 bytes wide and so dereferencing the offset produces garbage. [jc: taking suggestion by Linus to use uint32_t] Signed-off-by: Dennis Stosberg <dennis@stosberg.net> Signed-off-by: Junio C Hamano <junkio@cox.net>
2006-05-10fix diff-delta bad memory accessNicolas Pitre
It cannot be assumed that the given buffer will never be moved when shrinking the allocated memory size with realloc(). So let's ignore that optimization for now. This patch makes Electric Fence happy on Linux. Signed-off-by: Nicolas Pitre <nico@cam.org> Acked-by: Linus Torvalds <torvalds@osdl.org> Signed-off-by: Junio C Hamano <junkio@cox.net>
2006-05-10Merge branch 'fix'Junio C Hamano
* fix: checkout: use --aggressive when running a 3-way merge (-m). revert/cherry-pick: use aggressive merge.
2006-05-10checkout: use --aggressive when running a 3-way merge (-m).Junio C Hamano
After doing an in-index 3-way merge, we always do the stock "merge-index merge-one-file" without doing anything fancy; use of --aggressive helps performance quite a bit. Signed-off-by: Junio C Hamano <junkio@cox.net>
2006-05-10revert/cherry-pick: use aggressive merge.Linus Torvalds
After doing an in-index 3-way merge, we always do the stock "merge-index merge-one-file" without doing anything fancy; use of --aggressive helps performance quite a bit. Signed-off-by: Junio C Hamano <junkio@cox.net>
2006-05-10builtin-grep: -F (--fixed-strings)Junio C Hamano
Signed-off-by: Junio C Hamano <junkio@cox.net>
2006-05-10builtin-grep: -w fixJunio C Hamano
Signed-off-by: Junio C Hamano <junkio@cox.net>
2006-05-10builtin-grep: typofixJunio C Hamano
Signed-off-by: Junio C Hamano <junkio@cox.net>
2006-05-09Merge branch 'jc/clean'Junio C Hamano
* jc/clean: Teach git-clean optional <paths>... parameters.
2006-05-09Merge branch 'mw/alternates'Junio C Hamano
* mw/alternates: clone: don't clone the info/alternates file test case for transitive info/alternates Transitively read alternatives
2006-05-09Merge branch 'jc/xsha1'Junio C Hamano
* jc/xsha1: get_sha1() - fix infinite loop on nonexistent stage. get_sha1(): :path and :[0-3]:path to extract from index.
2006-05-09Merge branch 'jc/again'Junio C Hamano
* jc/again: Fix users of prefix_path() to free() only when necessary update-index --again: take optional pathspecs update-index --again
2006-05-09Merge branch 'np/delta'Junio C Hamano
* np/delta: improve diff-delta with sparse and/or repetitive data tiny optimization to diff-delta replace adler32 with Rabin's polynomial in diff-delta use delta index data when finding best delta matches split the diff-delta interface
2006-05-09Merge branch 'jc/bindiff'Junio C Hamano
* jc/bindiff: improve base85 generated assembly code binary diff and apply: testsuite. binary diff: further updates. binary patch.
2006-05-09Merge branch 'fix'Junio C Hamano
* fix: read-cache.c: use xcalloc() not calloc() apply: fix infinite loop with multiple patches with --index
2006-05-09Merge branch 'tojunio' of ↵Junio C Hamano
http://locke.catalyst.net.nz/git/git-martinlanghoff into ml/cvs * 'tojunio' of http://locke.catalyst.net.nz/git/git-martinlanghoff: Change to allow subdir updates from Eclipse Many fixes for most operations in Eclipse. Added logged warnings for CVS error returns cvsserver: use git-rev-list instead of git-log git-cvsexportcommit: Add -f(orce) and -m(essage prefix) flags, small cleanups.
2006-05-09read-cache.c: use xcalloc() not calloc()Yakov Lerner
Elsewhere we use xcalloc(); we should consistently do so. Signed-off-by: Yakov Lerner <iler.ml@gmail.com> Signed-off-by: Junio C Hamano <junkio@cox.net>
2006-05-09apply: fix infinite loop with multiple patches with --indexEric Wong
When multiple patches are passed to git-apply, it will attempt to open multiple file descriptors to an index, which means multiple entries will be in the circular cache_file_list. This change makes git-apply only open the index once and write the index at exit. Signed-off-by: Eric Wong <normalperson@yhbt.net> Signed-off-by: Junio C Hamano <junkio@cox.net>
2006-05-09builtin-grep: tighten argument parsing.Junio C Hamano
I mistyped git grep next -e '"^@"' '*.c' and got many hits that contain "next" without complaint. Obviously what I meant to say was: git grep -e '"^@"' next -- '*.c' This tightens the argument parsing rule a bit: - All "grep" parameters should come first; - If there is no -e nor -f to specify pattern, the first non option string is the parameter; - After that, zero or more revs can follow. - An optional '--' can be present, and is skipped. - All the rest are pathspecs. If '--' was not there, they must be paths that exist in the working tree. Signed-off-by: Junio C Hamano <junkio@cox.net>
2006-05-08Teach git-clean optional <paths>... parameters.Junio C Hamano
When optional paths arguments are given, git-clean passes them to underlying git-ls-files; with this, you can say: git clean 'temp-*' to clean only the garbage files whose names begin with 'temp-'. Signed-off-by: Junio C Hamano <junkio@cox.net> Signed-off-by: Pavel Roskin <proski@gnu.org>
2006-05-08Merge branch 'fix'Junio C Hamano
* fix: Separate object name errors from usage errors Documentation: {caret} fixes (git-rev-list.txt) Fix "git diff --stat" with long filenames Fix repo-config set-multivar error return path.
2006-05-08Separate object name errors from usage errorsDmitry V. Levin
Separate object name errors from usage errors. Signed-off-by: Dmitry V. Levin <ldv@altlinux.org> Signed-off-by: Junio C Hamano <junkio@cox.net>
2006-05-08get_sha1() - fix infinite loop on nonexistent stage.Junio C Hamano
Signed-off-by: Junio C Hamano <junkio@cox.net>
2006-05-08Documentation: {caret} fixes (git-rev-list.txt)Junio C Hamano
Signed-off-by: Junio C Hamano <junkio@cox.net>
2006-05-08builtin-grep: documentationJunio C Hamano
Signed-off-by: Junio C Hamano <junkio@cox.net>
2006-05-08Teach -f <file> option to builtin-grep.Junio C Hamano
Signed-off-by: Junio C Hamano <junkio@cox.net>
2006-05-08improve base85 generated assembly codeNicolas Pitre
This code is arguably pretty hot, if you use binary patches of course. This patch helps gcc generate both smaller and faster code especially in the error free path. Signed-off-by: Nicolas Pitre <nico@cam.org> Signed-off-by: Junio C Hamano <junkio@cox.net>
2006-05-08Fix "git diff --stat" with long filenamesLinus Torvalds
When we cut off the front of a filename to make it fit on the line, we add a "..." in front. However, the way the "git diff" code was written, we will never reset the prefix back to the empty string, so every single filename afterwards will have the "..." prefix, whether appropriate or not. You can see this with "git diff v2.6.16.." on the current kernel tree, since there are filenames with long names that changed there: [ snip snip ] Documentation/filesystems/vfs.txt | 229 .../firmware_class/firmware_sample_driver.c | 3 .../firmware_sample_firmware_class.c | 1 ...Documentation/fujitsu/frv/kernel-ABI.txt | 192 ...Documentation/hwmon/w83627hf | 4 [ snip snip ] notice how the two Documentation/firmware** filenames caused the "..." to be added, but then the later filenames don't want it, and it also screws up the alignment of the line numbering afterwards. Trivially fixed by moving the declaration (and initial setting) of the "prefix" variable into the for-loop where it is used. Signed-off-by: Linus Torvalds <torvalds@osdl.org> Signed-off-by: Junio C Hamano <junkio@cox.net>
2006-05-08Fix repo-config set-multivar error return path.Junio C Hamano
This hopefully fixes the problem an earlier commit 5d8ee9ceb attemted to fix. Signed-off-by: Junio C Hamano <junkio@cox.net>
2006-05-07clone: don't clone the info/alternates fileMartin Waitz
Now that the cloned alternates file is parsed, too we don't need to copy it into our new repository, we just reference it. Signed-off-by: Martin Waitz <tali@admingilde.org> Signed-off-by: Junio C Hamano <junkio@cox.net>
2006-05-07test case for transitive info/alternatesMartin Waitz
Signed-off-by: Martin Waitz <tali@admingilde.org> Signed-off-by: Junio C Hamano <junkio@cox.net>
2006-05-07Transitively read alternativesMartin Waitz
When adding an alternate object store then add entries from its info/alternates files, too. Relative entries are only allowed in the current repository. Loops and duplicate alternates through multiple repositories are ignored. Just to be sure that nothing breaks it is not allow to build deep nesting levels using info/alternates. Signed-off-by: Martin Waitz <tali@admingilde.org> Signed-off-by: Junio C Hamano <junkio@cox.net>
2006-05-07Change to allow subdir updates from EclipseMartyn Smith
(Now you can rightclick any directory and select team-update/team-commit) and it should work
2006-05-07Merge branch 'fix'Junio C Hamano
* fix: repack: honor -d even when no new pack was created clone: keep --reference even with -l -s repo-config: document what value_regexp does a bit more clearly. Release config lock if the regex is invalid core-tutorial.txt: escape asterisk
2006-05-07Sparse fix for builtin-diffPeter Hagervall
You gotta love sparse: builtin-diff.c:88:4: error: Just how const do you want this type to be? Signed-off-by: Peter Hagervall <hager@cs.umu.se> Signed-off-by: Junio C Hamano <junkio@cox.net>
2006-05-07repack: honor -d even when no new pack was createdMartin Waitz
If all objects are reachable via an alternate object store then we still have to remove all obsolete local packs. Signed-off-by: Martin Waitz <tali@admingilde.org> Signed-off-by: Junio C Hamano <junkio@cox.net>
2006-05-07clone: keep --reference even with -l -sMartin Waitz
Both -l -s and --reference update objects/info/alternates and used to write over each other. Signed-off-by: Martin Waitz <tali@admingilde.org> Signed-off-by: Junio C Hamano <junkio@cox.net>
2006-05-07Many fixes for most operations in Eclipse.Martyn Smith
* Implemented global -n option * Implemented "Questionable" * Fixed Directory method, I _believe_ it's now correct in both cmdline and Eclipse. * Directory method Now looks for localdir of "." and compares the repo dir, uses THIS as a basis for all directory level calculations. * Added extra parameter to filenamesplit() to force stripping of "prepended" directory name. This ensures commits/updates etc work from any directory in the source tree. * Modified argsfromdir() so it is "always" called. This means that when the client specifies a directory, the method can detect this and behave accordingly (this is currently only implemented for the '.' directory) * Fixed "commit" method to correctly work from in a subdir
2006-05-07repo-config: document what value_regexp does a bit more clearly.Junio C Hamano
Signed-off-by: Junio C Hamano <junkio@cox.net>
2006-05-07Release config lock if the regex is invalidPavel Roskin
Signed-off-by: Pavel Roskin <proski@gnu.org> Signed-off-by: Junio C Hamano <junkio@cox.net>