summaryrefslogtreecommitdiff
AgeCommit message (Collapse)AuthorFilesLines
2012-09-07fetch --all: pass --tags/--no-tags through to each remoteLibravatar Dan Johnson2-0/+34
When fetch is invoked with --all, we need to pass the tag-following preference to each individual fetch; without this, we will always auto-follow tags, preventing us from fetching the remote tags into a remote-specific namespace, for example. Reported-by: Oswald Buddenhagen <ossi@kde.org> Signed-off-by: Dan Johnson <ComputerDruid@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2012-09-02submodule: use argv_array instead of hand-building arraysLibravatar Jens Lehmann3-17/+19
fetch_populated_submodules() allocates the full argv array it uses to recurse into the submodules from the number of given options plus the six argv values it is going to add. It then initializes it with those values which won't change during the iteration and copies the given options into it. Inside the loop the two argv values different for each submodule get replaced with those currently valid. However, this technique is brittle and error-prone (as the comment to explain the magic number 6 indicates), so let's replace it with an argv_array. Instead of replacing the argv values, push them to the argv_array just before the run_command() call (including the option separating them) and pop them from the argv_array right after that. Signed-off-by: Jens Lehmann <Jens.Lehmann@web.de> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2012-09-02fetch: use argv_array instead of hand-building arraysLibravatar Jeff King1-22/+25
Fetch invokes itself recursively when recursing into submodules or handling "fetch --multiple". In both cases, it builds the child's command line by pushing options onto a statically-sized array. In both cases, the array is currently just big enough to handle the largest possible case. However, this technique is brittle and error-prone, so let's replace it with a dynamic argv_array. Signed-off-by: Jeff King <peff@peff.net> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2012-09-02argv-array: fix bogus cast when freeing arrayLibravatar Jeff King1-1/+1
Since the array struct stores a "const char **" argv member (for compatibility with most of our argv-taking functions), we have to cast away the const-ness when freeing its elements. However, we used the wrong type when doing so. It doesn't make a difference since free() take a void pointer anyway, but it can be slightly confusing to a reader. Signed-off-by: Jeff King <peff@peff.net> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2012-09-02argv-array: add pop functionLibravatar Jeff King3-0/+14
Sometimes we build a set of similar command lines, differing only in the final arguments (e.g., "fetch --multiple"). To use argv_array for this, you have to either push the same set of elements repeatedly, or break the abstraction by manually manipulating the array's internal members. Instead, let's provide a sanctioned "pop" function to remove elements from the end. Signed-off-by: Jeff King <peff@peff.net> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2012-04-29Merge branch 'jk/repack-no-explode-objects-from-old-pack'Libravatar Junio C Hamano7-53/+107
Avoid writing out unreachable objects as loose objects when repacking, if such loose objects will immediately pruned due to its age anyway. By Jeff King * jk/repack-no-explode-objects-from-old-pack: gc: use argv-array for sub-commands argv-array: add a new "pushl" method argv-array: refactor empty_argv initialization gc: do not explode objects which will be immediately pruned
2012-04-29Merge git://git.bogomips.org/git-svnLibravatar Junio C Hamano1-2/+18
By Matthijs Kooijman via Eric Wong * git://git.bogomips.org/git-svn: git-svn: use platform specific auth providers
2012-04-27The sixth batch of topics graduated to 'master'Libravatar Junio C Hamano1-0/+24
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2012-04-27Merge branch 'jc/merge-reduce-parents-early'Libravatar Junio C Hamano5-70/+275
Octopus merge strategy did not reduce heads that are recorded in the final commit correctly. By Junio C Hamano (4) and Michał Kiedrowicz (1) * jc/merge-reduce-parents-early: fmt-merge-msg: discard needless merge parents builtin/merge.c: reduce parents early builtin/merge.c: collect other parents early builtin/merge.c: remove "remoteheads" global variable merge tests: octopus with redundant parents
2012-04-27Merge branch 'js/fast-import-test-9300'Libravatar Junio C Hamano1-34/+54
By Johannes Sixt * js/fast-import-test-9300: t9300-fast-import: avoid 'exit' in test_expect_success snippets
2012-04-27Merge branch 'rt/cherry-revert-conflict-summary'Libravatar Junio C Hamano1-1/+1
In the older days, the header "Conflicts:" in "cherry-pick" and "merge" was separated by a blank line from the list of paths that follow for readability, but when "merge" was rewritten in C, we lost it by mistake. Remove the newline from "cherry-pick" to make them match again. By Ralf Thielow * rt/cherry-revert-conflict-summary: sequencer: remove additional blank line
2012-04-27Merge branch 'cb/maint-report-mount-point-correctly-in-setup'Libravatar Junio C Hamano1-9/+13
The filesystem boundary was not correctly reported when .git directory discovery stopped at a mount point. By Clemens Buchacher * cb/maint-report-mount-point-correctly-in-setup: properly keep track of current working directory
2012-04-27Merge branch 'cb/cherry-pick-rev-path-confusion'Libravatar Junio C Hamano3-11/+19
The command line parser choked "git cherry-pick $name" when $name can be both revision name and a pathname, even though $name can never be a path in the context of the command. The issue the patch addresses is real, but the way it is implemented felt unnecessarily invasive a bit. It may be cleaner for this caller to add the "--" to the end of the argv_array it passes to setup_revisions(). By Clemens Buchacher * cb/cherry-pick-rev-path-confusion: cherry-pick: do not expect file arguments
2012-04-27Merge branch 'cb/http-multi-curl-auth'Libravatar Junio C Hamano2-10/+26
Fixes http authentication breakage when we keep multiple HTTP requests in flight using curl-multi. By Jeff King (3) and Clemens Buchacher (1) * cb/http-multi-curl-auth: http: use newer curl options for setting credentials http: clean up leak in init_curl_http_auth fix http auth with multiple curl handles http auth fails with multiple curl handles
2012-04-27git-svn: use platform specific auth providersLibravatar Matthijs Kooijman1-2/+18
On Linux, this makes authentication using passwords from gnome-keyring and kwallet work (only the former was tested). On Mac OS X, this allows using the OS X Keychain. Signed-off-by: Matthijs Kooijman <matthijs@stdin.nl> Acked-by: Eric Wong <normalperson@yhbt.net>
2012-04-26Update draft release notes to 1.7.11Libravatar Junio C Hamano1-53/+11
A handful of topics have been merged to maintenance releases, and the first half of 6th batch graduates to 'master'. Signed-off-by: Junio C Hamano <gitster@pobox.com>
2012-04-26Merge branch 'rl/maint-stash-i18n-save-error'Libravatar Junio C Hamano1-2/+2
The i18n of error message "git stash save" was not properly done. By Ross Lagerwall * rl/maint-stash-i18n-save-error: stash: use eval_gettextln correctly
2012-04-26Merge branch 'mb/fetch-call-a-non-branch-a-ref'Libravatar Junio C Hamano2-4/+43
The report from "git fetch" said "new branch" even for a non branch ref. By Marc Branchaud * mb/fetch-call-a-non-branch-a-ref: fetch: describe new refs based on where it came from fetch: Give remote_ref to update_local_ref() as well
2012-04-26Merge branch 'jm/maint-strncpy-diff-no-index'Libravatar Junio C Hamano1-21/+17
The "diff --no-index" codepath used limited-length buffers, risking pathnames getting truncated. Update it to use the strbuf API. By Jim Meyering (1) and Junio C Hamano (1) * jm/maint-strncpy-diff-no-index: diff --no-index: use strbuf for temporary pathnames diff: avoid stack-buffer-read-overrun for very long name
2012-04-26Merge bundle error message fix inLibravatar Junio C Hamano6-4/+105
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2012-04-26Start preparing for 1.7.10.1Libravatar Junio C Hamano2-1/+51
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2012-04-26Merge branch 'jk/run-command-eacces' into maintLibravatar Junio C Hamano6-7/+86
When PATH contains an unreadable directory, alias expansion code did not kick in, and failed with an error that said "git-subcmd" was not found. By Jeff King (1) and Ramsay Jones (1) * jk/run-command-eacces: run-command: treat inaccessible directories as ENOENT compat/mingw.[ch]: Change return type of exec functions to int
2012-04-26Merge branch 'jc/push-upstream-sanity' into maintLibravatar Junio C Hamano2-8/+72
The 'push to upstream' implementation was broken in some corner cases. "git push $there" without refspec, when the current branch is set to push to a remote different from $there, used to push to $there using the upstream information to a remote unreleated to $there. * jc/push-upstream-sanity: push: error out when the "upstream" semantics does not make sense
2012-04-26Merge branch 'jc/maint-clean-nested-worktree-in-subdir' into maintLibravatar Junio C Hamano2-11/+43
"git clean -d -f" (not "-d -f -f") is supposed to protect nested working trees of independent git repositories that exist in the current project working tree from getting removed, but the protection applied only to such working trees that are at the top-level of the current project by mistake. * jc/maint-clean-nested-worktree-in-subdir: clean: preserve nested git worktree in subdirectories
2012-04-26Merge branch 'jk/diff-no-rename-empty' into maintLibravatar Junio C Hamano9-14/+45
Rename detection logic used to match two empty files as renames during merge-recursive, leading unnatural mismerges. By Jeff King * jk/diff-no-rename-empty: merge-recursive: don't detect renames of empty files teach diffcore-rename to optionally ignore empty content make is_empty_blob_sha1 available everywhere drop casts from users EMPTY_TREE_SHA1_BIN
2012-04-26Merge branch 'rs/combine-diff-zero-context-at-the-beginning' into maintLibravatar Junio C Hamano1-1/+1
An age-old corner case bug in combine diff (only triggered with -U0 and the hunk at the beginning of the file needs to be shown) has been fixed. By René Scharfe * rs/combine-diff-zero-context-at-the-beginning: combine-diff: fix loop index underflow
2012-04-26Merge branch 'jc/commit-unedited-template' into maintLibravatar Junio C Hamano3-24/+65
When "git commit --template F" errors out because the user did not touch the message, it claimed that it aborts due to "empty message", which was utterly wrong. By Junio C Hamano (4) and Adam Monsen (1) * jc/commit-unedited-template: Documentation/git-commit: rephrase the "initial-ness" of templates git-commit.txt: clarify -t requires editing message commit: rephrase the error when user did not touch templated log message commit: do not trigger bogus "has templated message edited" check t7501: test the right kind of breakage
2012-04-26Merge branch 'jk/add-p-skip-conflicts' into maintLibravatar Junio C Hamano2-7/+44
"git add -p" is not designed to deal with unmerged paths but did not exclude them and tried to apply funny patches only to fail. By Jeff King * jk/add-p-skip-conflicts: add--interactive: ignore unmerged entries in patch mode
2012-04-26Merge branch 'jc/commit-hook-authorship' into maintLibravatar Junio C Hamano5-47/+141
"git commit --author=$name" did not tell the name that was being recorded in the resulting commit to hooks, even though it does do so when the end user overrode the authorship via the "GIT_AUTHOR_NAME" environment variable. * jc/commit-hook-authorship: commit: pass author/committer info to hooks t7503: does pre-commit-hook learn authorship? ident.c: add split_ident_line() to parse formatted ident line
2012-04-26Merge branch 'tr/maint-word-diff-regex-sticky' into maintLibravatar Junio C Hamano2-56/+102
The regexp configured with diff.wordregex was incorrectly reused across files. By Thomas Rast (2) and Johannes Sixt (1) * tr/maint-word-diff-regex-sticky: diff: tweak a _copy_ of diff_options with word-diff diff: refactor the word-diff setup from builtin_diff_cmd t4034: diff.*.wordregex should not be "sticky" in --word-diff
2012-04-26Merge branch 'jh/notes-merge-in-git-dir-worktree' into maintLibravatar Junio C Hamano4-32/+73
Running "notes merge --commit" failed to perform correctly when run from any directory inside $GIT_DIR/. When "notes merge" stops with conflicts, $GIT_DIR/NOTES_MERGE_WORKTREE is the place a user edits to resolve it. By Johan Herland (3) and Junio C Hamano (1) * jh/notes-merge-in-git-dir-worktree: notes-merge: Don't remove .git/NOTES_MERGE_WORKTREE; it may be the user's cwd notes-merge: use opendir/readdir instead of using read_directory() t3310: illustrate failure to "notes merge --commit" inside $GIT_DIR/ remove_dir_recursively(): Add flag for skipping removal of toplevel dir
2012-04-26Sync with 1.7.9.7Libravatar Junio C Hamano5-4/+55
2012-04-26Git 1.7.9.7Libravatar Junio C Hamano3-2/+16
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2012-04-26Sync with 1.7.8.6Libravatar Junio C Hamano4-3/+40
2012-04-26Git 1.7.8.6Libravatar Junio C Hamano4-3/+27
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2012-04-26Sync with 1.7.7.7Libravatar Junio C Hamano3-2/+16
2012-04-26Git 1.7.7.7Libravatar Junio C Hamano4-3/+18
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2012-04-26diff --no-index: use strbuf for temporary pathnamesLibravatar Junio C Hamano1-23/+17
Instead of using limited-length buffers and risking of pathname truncation, we should be taking advantage of strbuf API nowadays. Signed-off-by: Junio C Hamano <gitster@pobox.com>
2012-04-26bundle: remove stray single-quote from error messageLibravatar Jonathan Nieder1-1/+1
After running rev-list --boundary to retrieve the list of boundary commits, "git bundle create" runs its own revision walk. If in this stage git encounters an unfamiliar option, it writes a message with an unbalanced quotation mark: error: unrecognized argument: --foo' Drop the stray quote to match the "unrecognized argument: %s" message used elsewhere and save translators some work. This is mostly a futureproofing measure: for now, the "rev-list --boundary" command catches most strange arguments on its own and the above message is not seen unless you try something esoteric like "git bundle create test.bundle --header HEAD". Reported-by: Junio C Hamano <gitster@pobox.com> Signed-off-by: Jonathan Nieder <jrnieder@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2012-04-24The fifth batch of topics graduated to 'master'Libravatar Junio C Hamano1-0/+26
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2012-04-24Merge branch 'fc/completion-tests'Libravatar Junio C Hamano2-9/+256
By Felipe Contreras (4) and others * fc/completion-tests: completion: fix completion after 'git --option <TAB>' completion: avoid trailing space for --exec-path completion: add missing general options completion: simplify by using $prev completion: simplify __gitcomp_1 tests: add tests for the __gitcomp() completion helper function tests: add initial bash completion tests
2012-04-24Merge branch 'cc/fix-missing-va-end-in-revert'Libravatar Junio C Hamano1-0/+1
By Christian Couder * cc/fix-missing-va-end-in-revert: revert: add missing va_end
2012-04-24Merge branch 'zj/upstream-error-message'Libravatar Junio C Hamano2-7/+94
Error message given when @{u} is used for a branch without its upstream configured have been clatified. By Zbigniew Jędrzejewski-Szmek * zj/upstream-error-message: i18n: mark @{upstream} error messages for translation Be more specific if upstream branch is not tracked Provide better message for barnhc_wiht_tpyo@{u} Provide branch name in error message when using @{u} t1507: add tests to document @{upstream} behaviour
2012-04-24Merge branch 'mk/gitweb-diff-hl'Libravatar Junio C Hamano2-87/+244
"gitweb" learns to highlight the patch it outputs even more. By Michał Kiedrowicz (7) and Jakub Narębski (1) * mk/gitweb-diff-hl: gitweb: Refinement highlightning in combined diffs gitweb: Highlight interesting parts of diff gitweb: Push formatting diff lines to print_diff_chunk() gitweb: Use print_diff_chunk() for both side-by-side and inline diffs gitweb: Extract print_sidebyside_diff_lines() gitweb: Pass esc_html_hl_regions() options to esc_html() gitweb: esc_html_hl_regions(): Don't create empty <span> elements gitweb: Use descriptive names in esc_html_hl_regions()
2012-04-24Merge branch 'it/fetch-pack-many-refs'Libravatar Junio C Hamano6-6/+162
When "git fetch" encounters repositories with too many references, the command line of "fetch-pack" that is run by a helper e.g. remote-curl, may fail to hold all of them. Now such an internal invocation can feed the references through the standard input of "fetch-pack". By Ivan Todoroski * it/fetch-pack-many-refs: remote-curl: main test case for the OS command line overflow fetch-pack: test cases for the new --stdin option remote-curl: send the refs to fetch-pack on stdin fetch-pack: new --stdin option to read refs from stdin
2012-04-24Merge branch 'pw/fast-import-dataref-parsing'Libravatar Junio C Hamano2-33/+364
The parser in "fast-import" did not diagnose ":9" style references that is not followed by required SP/LF as an error. By Pete Wyckoff * pw/fast-import-dataref-parsing: fast-import: tighten parsing of datarefs
2012-04-24Merge branch 'mh/ref-api'Libravatar Junio C Hamano2-363/+659
Allows walking only a sub-hierarchy in refs/*. By Michael Haggerty * mh/ref-api: do_for_each_ref(): only iterate over the subtree that was requested refs: store references hierarchically sort_ref_dir(): simplify logic refs.c: rename ref_array -> ref_dir struct ref_entry: nest the value part in a union check_refname_component(): return 0 for zero-length components free_ref_entry(): new function names_conflict(): simplify implementation repack_without_ref(): reimplement using do_for_each_ref_in_array() do_for_each_ref_in_arrays(): new function do_for_each_ref_in_array(): new function refs: manage current_ref within do_one_ref() refs.c: reorder definitions more logically
2012-04-24Merge branch 'hv/submodule-recurse-push'Libravatar Junio C Hamano16-21/+341
"git push --recurse-submodules" learns to optionally look into the histories of submodules bound to the superproject and push them out. By Heiko Voigt * hv/submodule-recurse-push: push: teach --recurse-submodules the on-demand option Refactor submodule push check to use string list instead of integer Teach revision walking machinery to walk multiple times sequencially
2012-04-24git-svn: drop redundant blocking of SIGPIPELibravatar Roman Kagan1-1/+1
Now that SIGPIPE is ignored there's no point blocking it. Signed-off-by: Roman Kagan <rkagan@mail.ru> Acked-by: Eric Wong <normalperson@yhbt.net>
2012-04-24git-svn: ignore SIGPIPELibravatar Roman Kagan1-0/+5
In HTTP with keep-alive it's not uncommon for the client to notice that the server decided to stop maintaining the current connection only when sending a new request. This naturally results in -EPIPE and possibly SIGPIPE. The subversion library itself makes no provision for SIGPIPE. Some combinations of the underlying libraries do (typically SIG_IGN-ing it), some don't. Presumably for that reason all subversion commands set SIGPIPE to SIG_IGN early in their main()-s. So should we. This, together with the previous patch, fixes the notorious "git-svn died of signal 13" problem (see e.g. http://thread.gmane.org/gmane.comp.version-control.git/134936). Signed-off-by: Roman Kagan <rkagan@mail.ru> Acked-by: Eric Wong <normalperson@yhbt.net>