summaryrefslogtreecommitdiff
path: root/builtin-fetch--tool.c
AgeCommit message (Collapse)Author
2007-09-19Use xmemdupz() in many places.Pierre Habouzit
Signed-off-by: Pierre Habouzit <madcoder@debian.org> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2007-09-17Now that cache.h needs strbuf.h, remove useless includes.Pierre Habouzit
Signed-off-by: Pierre Habouzit <madcoder@debian.org> Acked-by: Linus Torvalds <torvalds@linux-foundation.org> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2007-09-10Use strbuf_read in builtin-fetch-tool.c.Pierre Habouzit
xrealloc.use --; Signed-off-by: Pierre Habouzit <madcoder@debian.org> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2007-09-05Function for updating refs.Carlos Rica
A function intended to be called from builtins updating refs by locking them before write, specially those that came from scripts using "git update-ref". [jc: with minor fixups] Signed-off-by: Carlos Rica <jasampler@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2007-07-15Make every builtin-*.c file #include "builtin.h"Peter Hagervall
Make every builtin-*.c file #include "builtin.h". Also takes care of some declaration/definition mismatches. Signed-off-by: Peter Hagervall <hager@cs.umu.se> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2007-05-20Merge branch 'sv/checkout'Junio C Hamano
* sv/checkout: git-update-ref: add --no-deref option for overwriting/detaching ref
2007-05-16Ensure return value from xread() is always stored into an ssize_tJohan Herland
This patch fixes all calls to xread() where the return value is not stored into an ssize_t. The patch should not have any effect whatsoever, other than putting better/more appropriate type names on variables. Signed-off-by: Johan Herland <johan@herland.net> Signed-off-by: Junio C Hamano <junkio@cox.net>
2007-05-10git-update-ref: add --no-deref option for overwriting/detaching refSven Verdoolaege
git-checkout is also adapted to make use of this new option instead of the handcrafted command sequence. Signed-off-by: Sven Verdoolaege <skimo@kotnet.org> Signed-off-by: Junio C Hamano <junkio@cox.net>
2007-04-29Merge branch 'maint'Junio C Hamano
* maint: http.c: Fix problem with repeated calls of http_init Add missing reference to GIT_COMMITTER_DATE in git-commit-tree documentation Fix import-tars fix. Update .mailmap with "Michael" Do not barf on too long action description Catch empty pathnames in trees during fsck Don't allow empty pathnames in fast-import import-tars: be nice to wrong directory modes git-svn: Added 'find-rev' command git shortlog documentation: add long options and fix a typo
2007-04-29Do not barf on too long action descriptionJunio C Hamano
Reflog message is primarily about easier identification, and leaving truncated entry is much better than dying. Signed-off-by: Junio C Hamano <junkio@cox.net>
2007-04-24git-fetch: Fix "argument list too long"OGAWA Hirofumi
If $ls_remote_result was too long, git-fetch--tool -s pick-rref "$rref" "$ls_remote_result" in git-fetch will fail with "argument list too long". This patch fixes git-fetch--tool and git-fetch by passing $ls_remote_result via stdin. Signed-off-by: OGAWA Hirofumi <hirofumi@mail.parknet.co.jp> Signed-off-by: Junio C Hamano <junkio@cox.net>
2007-04-10git-fetch--tool pick-rrefJunio C Hamano
This script helper takes list of fully qualified refnames and results from ls-remote and grabs only the lines for the named refs from the latter. Signed-off-by: Junio C Hamano <junkio@cox.net>
2007-03-01builtin-fetch--tool: fix reflog notes.Junio C Hamano
Also the verbose output had unnecessary SHA1 and not-for-merge markers leaked because append_fetch_head() cheated Signed-off-by: Junio C Hamano <junkio@cox.net>
2007-03-01git-fetch: retire update-local-ref which is not used anymore.Junio C Hamano
Signed-off-by: Junio C Hamano <junkio@cox.net>
2007-02-28builtin-fetch--tool: make sure not to overstep ls-remote-result buffer.Junio C Hamano
Signed-off-by: Junio C Hamano <junkio@cox.net>
2007-02-28fetch--tool: fix uninitialized buffer when reading from stdinJunio C Hamano
The original code allocates too much space and forgets to NUL terminate the string. Signed-off-by: Junio C Hamano <junkio@cox.net>
2007-02-27builtin-fetch--tool: adjust to updated sha1_object_info().Junio C Hamano
Signed-off-by: Junio C Hamano <junkio@cox.net>
2007-02-14Allow fetch--tool to read from stdinJulian Phillips
If the reflist is "-" then read the reflist data from stdin instead, this will allow the passing of more than 128K of reflist data - which won't fit in the environment passed by execve. Signed-off-by: Julian Phillips <julian@quantumfyre.co.uk> Signed-off-by: Junio C Hamano <junkio@cox.net>
2007-02-14git-fetch: rewrite expand_ref_wildcard in CJunio C Hamano
This does not seem to make measurable improvement when dealing with 1000 unpacked refs, but we would need something like it if we were to do a full rewrite in C somedaoy. Signed-off-by: Junio C Hamano <junkio@cox.net>
2007-02-14git-fetch: rewrite another shell loop in CJunio C Hamano
Move another shell loop that canonicalizes the list of refs for underlying git-fetch-pack and fetch-native-store into C. This seems to shave the runtime for the same 1000 branch repository from 30 seconds down to 15 seconds (it used to be 2 and half minutes with the original version). Signed-off-by: Junio C Hamano <junkio@cox.net>
2007-02-14git-fetch: move more code into C.Junio C Hamano
This adds "native-store" subcommand to git-fetch--tool to move a huge loop implemented in shell into C. This shaves about 70% of the runtime to fetch and update 1000 tracking branches with a single fetch. Signed-off-by: Junio C Hamano <junkio@cox.net>
2007-02-14git-fetch--tool: start rewriting parts of git-fetch in C.Junio C Hamano
Signed-off-by: Junio C Hamano <junkio@cox.net>