summaryrefslogtreecommitdiff
path: root/t
AgeCommit message (Collapse)AuthorFilesLines
2012-09-07fetch --all: pass --tags/--no-tags through to each remoteLibravatar Dan Johnson1-0/+30
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-04-29Merge branch 'jk/repack-no-explode-objects-from-old-pack'Libravatar Junio C Hamano1-0/+14
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-27Merge branch 'jc/merge-reduce-parents-early'Libravatar Junio C Hamano3-7/+68
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 'cb/http-multi-curl-auth'Libravatar Junio C Hamano1-5/+10
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-26Merge branch 'mb/fetch-call-a-non-branch-a-ref'Libravatar Junio C Hamano1-0/+30
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-24Merge branch 'fc/completion-tests'Libravatar Junio C Hamano1-0/+243
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 'zj/upstream-error-message'Libravatar Junio C Hamano1-3/+78
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 'it/fetch-pack-many-refs'Libravatar Junio C Hamano2-0/+97
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 Hamano1-0/+287
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 'hv/submodule-recurse-push'Libravatar Junio C Hamano2-0/+127
"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-23Merge branch 'bw/test-fix-grep-gnuism'Libravatar Junio C Hamano1-2/+2
Fix two places that were the only place in the test suite that gave "a\+" to platform grep and expected it to mean one or more "a", which is a blatant GNUism. * bw/test-fix-grep-gnuism: t9400: fix gnuism in grep
2012-04-23Merge branch 'jn/more-i18ncmp'Libravatar Junio C Hamano3-8/+8
By Jonathan Nieder * jn/more-i18ncmp: test: am of empty patch should not succeed test: use test_i18ncmp for "Patch format detection failed" message test: do not rely on US English tracking-info messages
2012-04-23Merge branch 'lp/maint-diff-three-dash-with-graph'Libravatar Junio C Hamano1-0/+290
"log -p --graph" used with "--stat" had a few formatting error. By Lucian Poston * lp/maint-diff-three-dash-with-graph: t4202: add test for "log --graph --stat -p" separator lines log --graph: fix break in graph lines log --graph --stat: three-dash separator should come after graph lines
2012-04-23Merge branch 'sl/test-wc-l-line-count'Libravatar Junio C Hamano19-74/+65
By Stefano Lattarini * sl/test-wc-l-line-count: tests: modernise style: more uses of test_line_count
2012-04-23Merge branch 'rl/show-empty-prefix'Libravatar Junio C Hamano1-1/+1
"git rev-parse --show-prefix" emitted nothing when run at the top-level of the working tree, while "git rev-parse --show-cdup" gave an empty line. Make them consistent. By Ross Lagerwall * rl/show-empty-prefix: rev-parse --show-prefix: add in trailing newline
2012-04-23Merge branch 'pw/git-p4'Libravatar Junio C Hamano12-184/+182
By Pete Wyckoff * pw/git-p4: git p4: use "git p4" directly in tests git p4: update name in script git-p4: move to toplevel
2012-04-23Merge branch 'jk/rebase-i-submodule-conflict-only'Libravatar Junio C Hamano1-0/+30
Giving "--continue" to a conflicted "rebase -i" session skipped a commit that only results in changes to submodules. By John Keeping * jk/rebase-i-submodule-conflict-only: rebase -i continue: don't skip commits that only change submodules
2012-04-21completion: fix completion after 'git --option <TAB>'Libravatar SZEDER Gábor1-0/+17
The bash completion doesn't work when certain options to git itself are specified, e.g. 'git --no-pager <TAB>' errors out with error: invalid key: alias.--no-pager The main _git() completion function finds out the git command name by looping through all the words on the command line and searching for the first word that is not a known option for the git command. Unfortunately the list of known git options was not updated in a long time, and newer options are not skipped but mistaken for a git command. Such a misrecognized "command" is then passed to __git_aliased_command(), which in turn passes it to a 'git config' query, hence the error. Currently the following options are misrecognized for a git command: -c --no-pager --exec-path --html-path --man-path --info-path --no-replace-objects --work-tree= --namespace= To fix this we could just update the list of options to be skipped, but the same issue will likely arise, if the git command learns a new option in the future. Therefore, to make it more future proof against new options, this patch changes that loop to skip all option-looking words, i.e. words starting with a dash. We also have to handle the '-c' option specially, because it takes a configutation parameter in a separate word, which must be skipped, too. [fc: added tests] Signed-off-by: SZEDER Gábor <szeder@ira.uka.de> Signed-off-by: Felipe Contreras <felipe.contreras@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2012-04-21completion: avoid trailing space for --exec-pathLibravatar Jonathan Nieder1-1/+6
"--exec-path" looks to the completion script like an unambiguous successful completion, but it is wrong to emit a SP after it as if declaring that we are done with completion; the user could be trying to do git --exec-path; # print name of helper directory or git --exec-path=/path/to/alternative/helper/dir <subcommand> so the most helpful thing to do is to leave out the trailing space and leave it to the operator to type an equal sign or carriage return according to the situation. [fc: added tests] Cc: Andreas Schwab <schwab@linux-m68k.org> Reported-by: Felipe Contreras <felipe.contreras@gmail.com> Signed-off-by: Jonathan Nieder <jrnieder@gmail.com> Signed-off-by: Felipe Contreras <felipe.contreras@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2012-04-21completion: add missing general optionsLibravatar Felipe Contreras1-0/+16
And add relevant tests. Signed-off-by: Felipe Contreras <felipe.contreras@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2012-04-21tests: add tests for the __gitcomp() completion helper functionLibravatar SZEDER Gábor1-0/+85
These tests check that trailing space, prefix, and suffix are added correctly. Signed-off-by: SZEDER Gábor <szeder@ira.uka.de> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2012-04-20Merge branch 'ct/advise-push-default'Libravatar Junio C Hamano2-2/+2
Break down the cases in which "git push" fails due to non-ff into three categories, and give separate advise messages for each case. By Christopher Tiwald (2) and Jeff King (1) * ct/advise-push-default: Fix httpd tests that broke when non-ff push advice changed clean up struct ref's nonfastforward field push: Provide situational hints for non-fast-forward errors
2012-04-20Merge branch 'jk/run-command-eacces'Libravatar Junio C Hamano1-0/+13
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-20Merge branch 'jc/push-upstream-sanity'Libravatar Junio C Hamano1-0/+54
Fix broken 'push to upstream' implementation. "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-20Merge branch 'jc/fmt-merge-msg-people'Libravatar Junio C Hamano1-3/+24
The "fmt-merge-msg" command learns to list the primary contributors involved in the side topic you are merging. * jc/fmt-merge-msg-people: fmt-merge-msg: show those involved in a merged series
2012-04-20t9300-fast-import: avoid 'exit' in test_expect_success snippetsLibravatar Johannes Sixt1-34/+54
Exiting from a for-loop early using '|| break' does not propagate the failure code, and for this reason, the tests used just 'exit'. But this ends the test script with 'FATAL: Unexpected exit code 1' in the case of a failed test. Fix this by moving the loop into a shell function, from which we can simply return early. While at it, modernize the style of the affected test cases. Signed-off-by: Johannes Sixt <j6t@kdbg.org> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2012-04-19t9400: fix gnuism in grepLibravatar Junio C Hamano1-2/+2
Using "\+" in "grep" and expecting that it means one or more is a GNUism. Spell it in a dumb and portable way. Signed-off-by: Junio C Hamano <gitster@pobox.com>
2012-04-18fmt-merge-msg: discard needless merge parentsLibravatar Junio C Hamano1-1/+30
This is used by "git pull" to construct a merge message from list of remote refs. When pulling redundant set of refs, however, it did not filter them even though the merge itself discards them as unnecessary. Teach the command to do the same for consistency. Signed-off-by: Junio C Hamano <gitster@pobox.com>
2012-04-17builtin/merge.c: reduce parents earlyLibravatar Junio C Hamano3-3/+3
Instead of waiting until we record the parents of resulting merge, reduce redundant parents (including our HEAD) immediately after reading them. The change to t7602 illustrates the essence of the effect of this change. The octopus merge strategy used to be fed with redundant commits only to discard them as "up-to-date", but we no longer feed such redundant commits to it and the affected test degenerates to a regular two-head merge. And obviously the known-to-be-broken test in t6028 is now fixed. Signed-off-by: Junio C Hamano <gitster@pobox.com>
2012-04-17merge tests: octopus with redundant parentsLibravatar Michał Kiedrowicz3-7/+39
This happens when git merge is run to merge multiple commits that are descendants of current HEAD (or are HEAD). We've hit this while updating master to origin/master but accidentaly we called (while being on master): $ git merge master origin/master Here is a minimal testcase: $ git init a && cd a $ echo a >a && git add a $ git commit -minitial $ echo b >a && git add a $ git commit -msecond $ git checkout master^ $ git merge master master Fast-forwarding to: master Already up-to-date with master Merge made by the 'octopus' strategy. a | 2 +- 1 files changed, 1 insertions(+), 1 deletions(-) $ git cat-file commit HEAD tree eebfed94e75e7760540d1485c740902590a00332 parent bd679e85202280b263e20a57639a142fa14c2c64 author Michał Kiedrowicz <michal.kiedrowicz@gmail.com> 1329132996 +0100 committer Michał Kiedrowicz <michal.kiedrowicz@gmail.com> 1329132996 +0100 Merge branches 'master' and 'master' into HEAD Signed-off-by: Michał Kiedrowicz <michal.kiedrowicz@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2012-04-17fetch: describe new refs based on where it came fromLibravatar Marc Branchaud1-0/+30
update_local_ref() used to say "[new branch]" when we stored a new ref outside refs/tags/ hierarchy, but the message is more about what we fetched, so use the refname at the origin to make that decision. Also, only call a new ref a "branch" if it's under refs/heads/. Signed-off-by: Marc Branchaud <marcnarc@xiplink.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2012-04-16Merge branch 'jk/add-p-skip-conflicts'Libravatar Junio C Hamano1-0/+26
Excludes conflicted paths from "add -p" processing, as it is not prepared to handle them. By Jeff King * jk/add-p-skip-conflicts: add--interactive: ignore unmerged entries in patch mode
2012-04-16Merge branch 'jc/commit-unedited-template'Libravatar Junio C Hamano1-0/+14
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-16Merge branch 'wk/gitweb-snapshot-use-if-modified-since'Libravatar Junio C Hamano1-1/+59
Makes 'snapshot' request to "gitweb" honor If-Modified-Since: header, based on the commit date. By W. Trevor King * wk/gitweb-snapshot-use-if-modified-since: gitweb: add If-Modified-Since handling to git_snapshot(). gitweb: refactor If-Modified-Since handling gitweb: add `status` headers to git_feed() responses.
2012-04-16Merge branch 'jk/http-backend-keep-committer-ident-env'Libravatar Junio C Hamano2-0/+28
The smart-http backend used to always override GIT_COMMITTER_* variables with REMOTE_USER and REMOTE_ADDR. By Jeff King * jk/http-backend-keep-committer-ident-env: http-backend: respect existing GIT_COMMITTER_* variables
2012-04-16Merge branch 'jk/diff-no-rename-empty'Libravatar Junio C Hamano1-0/+16
Forbids rename detection logic from matching two empty files as renames during merge-recursive to prevent 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-16Merge branch 'jc/maint-clean-nested-worktree-in-subdir'Libravatar Junio C Hamano1-5/+22
"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-15Merge branch 'da/difftool-test'Libravatar Junio C Hamano1-0/+11
Makes sure "difftool" options can be given in any order. By David Aguilar * da/difftool-test: t7800: Test difftool passing arguments to diff
2012-04-15Merge branch 'zj/test-cred-helper-nicer-prove'Libravatar Junio C Hamano1-24/+45
Minor improvement to t0303. By Zbigniew Jędrzejewski-Szmek * zj/test-cred-helper-nicer-prove: t0303: resurrect commit message as test documentation t0303: immediately bail out w/o GIT_TEST_CREDENTIAL_HELPER
2012-04-15Merge branch 'jh/notes-merge-in-git-dir-worktree'Libravatar Junio C Hamano1-4/+23
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-15Merge branch 'tr/maint-word-diff-regex-sticky'Libravatar Junio C Hamano1-0/+36
The regexp configured with 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-15Merge branch 'jn/diffstat-tests'Libravatar Junio C Hamano16-259/+354
Some tests checked the "diff --stat" output when they do not have to, which unnecessarily made things harder to verify under GETTEXT_POISON. By Jonathan Nieder * jn/diffstat-tests: diffstat summary line varies by locale: miscellany test: use numstat instead of diffstat in binary-diff test test: use --numstat instead of --stat in "git stash show" tests test: test cherry-pick functionality and output separately test: modernize funny-names test style test: use numstat instead of diffstat in funny-names test test: use test_i18ncmp when checking --stat output
2012-04-15Merge branch 'jc/commit-hook-authorship'Libravatar Junio C Hamano1-0/+18
"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-15Merge branch 'nd/stream-more'Libravatar Junio C Hamano1-2/+36
Use API to read blob data in smaller chunks in more places to reduce the memory footprint. By Nguyễn Thái Ngọc Duy (6) and Junio C Hamano (1) * nd/stream-more: update-server-info: respect core.bigfilethreshold fsck: use streaming API for writing lost-found blobs show: use streaming API for showing blobs parse_object: avoid putting whole blob in core cat-file: use streaming API to print blobs Add more large blob test cases streaming: make streaming-write-entry to be more reusable
2012-04-15merge overwrites unstaged changes in renamed fileLibravatar Clemens Buchacher1-0/+9
Signed-off-by: Clemens Buchacher <drizzd@aon.at> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2012-04-15i18n: mark @{upstream} error messages for translationLibravatar Zbigniew Jędrzejewski-Szmek1-5/+5
Signed-off-by: Zbigniew Jędrzejewski-Szmek <zbyszek@in.waw.pl> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2012-04-15Be more specific if upstream branch is not trackedLibravatar Zbigniew Jędrzejewski-Szmek1-3/+3
If the branch configured as upstream didn't have a local tracking branch, git said "Upstream branch not found". We can be more helpful, and separate the cases when upstream is not configured, and when it is configured, but the upstream branch is not tracked in a local branch. The following configuration leads to the second scenario: [remote "origin"] url = ... fetch = refs/heads/master [branch "master"] remote = origin merge = refs/heads/master 'git pull' will work on master, but master@{upstream} is not defined. Signed-off-by: Zbigniew Jędrzejewski-Szmek <zbyszek@in.waw.pl> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2012-04-15Provide better message for barnhc_wiht_tpyo@{u}Libravatar Zbigniew Jędrzejewski-Szmek1-1/+1
Instead of just saying that no upstream exists for such branch, which is true but not very helpful, check that there's no refs/heads/barnhc_wiht_tpyo and tell it to the user. Signed-off-by: Zbigniew Jędrzejewski-Szmek <zbyszek@in.waw.pl> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2012-04-15Provide branch name in error message when using @{u}Libravatar Zbigniew Jędrzejewski-Szmek1-2/+2
When using @{u} or @{upstream} it is common to omit the branch name, implying current branch. If the upstream is not configured, the error message was "No upstream branch found for ''". When resolving '@{u}', branch_get() is called, which almost always returns a description of a branch. This allows us to use a branch name in the error message, even if the user said something like '@{u}'. The only case when branch_get() returns NULL is when HEAD points to so something which is not a branch. Of course this also means that no upstream is configured, but it is better to directly say that HEAD does not point to a branch. Signed-off-by: Zbigniew Jędrzejewski-Szmek <zbyszek@in.waw.pl> Signed-off-by: Junio C Hamano <gitster@pobox.com>