summaryrefslogtreecommitdiff
path: root/t
AgeCommit message (Collapse)Author
2013-07-01Merge branch 'maint'Junio C Hamano
* maint: t7500: fix flipped actual/expect lib-rebase: document exec_ in FAKE_LINES
2013-07-01Merge branch 'rr/remote-branch-config-refresh'Junio C Hamano
The original way to specify remote repository using .git/branches/ used to have a nifty feature. The code to support the feature was still in a function but the caller was changed not to call it 5 years ago, breaking that feature and leaving the supporting code unreachable. * rr/remote-branch-config-refresh: t/t5505-remote: test multiple push/pull in remotes-file ls-remote doc: don't encourage use of branches-file ls-remote doc: rewrite <repository> paragraph ls-remote doc: fix example invocation on git.git t/t5505-remote: test url-with-# in branches-file remote: remove dead code in read_branches_file() t/t5505-remote: use test_path_is_missing t/t5505-remote: test push-refspec in branches-file t/t5505-remote: modernize style
2013-07-01Merge branch 'ed/color-prompt'Junio C Hamano
Code clean-up for in-prompt status script (in contrib/). * ed/color-prompt: git-prompt.sh: add missing information in comments git-prompt.sh: do not print duplicate clean color code t9903: remove redundant tests git-prompt.sh: refactor colored prompt code t9903: add tests for git-prompt pcmode
2013-07-01Merge branch 'ap/rebase-multiple-fixups'Junio C Hamano
Having multiple "fixup!" on a line in the rebase instruction sheet did not work very well with "git rebase -i --autosquash". * ap/rebase-multiple-fixups: lib-rebase: style: use write_script, <<-\EOF rebase -i: handle fixup! fixup! in --autosquash
2013-07-01Merge branch 'kb/am-deprecate-resolved'Junio C Hamano
Promote "git am --continue" over "git am --resolved" for UI consistency. * kb/am-deprecate-resolved: am: replace uses of --resolved with --continue
2013-07-01Merge branch 'sg/bash-prompt'Junio C Hamano
* sg/bash-prompt: bash prompt: mention that PROMPT_COMMAND mode is faster bash prompt: avoid command substitution when finalizing gitstring bash prompt: avoid command substitution when checking for untracked files bash prompt: use bash builtins to check stash state bash prompt: use bash builtins to check for unborn branch for dirty state bash prompt: combine 'git rev-parse' for detached head bash prompt: combine 'git rev-parse' executions in the main code path bash prompt: use bash builtins to find out current branch bash prompt: use bash builtins to find out rebase state bash prompt: run 'git rev-parse --git-dir' directly instead of __gitdir() bash prompt: return early from __git_ps1() when not in a git repository bash prompt: print unique detached HEAD abbreviated object name bash prompt: add a test for symbolic link symbolic refs completion, bash prompt: move __gitdir() tests to completion test suite bash prompt: use 'write_script' helper in interactive rebase test bash prompt: fix redirection coding style in tests
2013-07-01Merge branch 'wk/doc-in-linux-3.x-era'Junio C Hamano
Update documentation to match more recent realities. * wk/doc-in-linux-3.x-era: Documentation: Update 'linux-2.6.git' -> 'linux.git' Documentation: Update the NFS remote examples to use the staging repo doc/clone: Pick more compelling paths for the --reference example doc/clone: Remove the '--bare -l -s' example
2013-07-01Merge branch 'jc/topo-author-date-sort'Junio C Hamano
"git log" learned the "--author-date-order" option, with which the output is topologically sorted and commits in parallel histories are shown intermixed together based on the author timestamp. * jc/topo-author-date-sort: t6003: add --author-date-order test topology tests: teach a helper to set author dates as well t6003: add --date-order test topology tests: teach a helper to take abbreviated timestamps t/lib-t6000: style fixes log: --author-date-order sort-in-topological-order: use prio-queue prio-queue: priority queue of pointers to structs toposort: rename "lifo" field
2013-07-01lib-rebase: style: use write_script, <<-\EOFAndrew Pimlott
Signed-off-by: Andrew Pimlott <andrew@pimlott.net> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2013-07-01t7500: fix flipped actual/expectAndrew Pimlott
Signed-off-by: Andrew Pimlott <andrew@pimlott.net> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2013-07-01lib-rebase: document exec_ in FAKE_LINESAndrew Pimlott
Signed-off-by: Andrew Pimlott <andrew@pimlott.net> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2013-06-30Merge branch 'maint'Junio C Hamano
* maint: Start preparing for 1.8.3.3 check-ignore doc: fix broken link to ls-files page test: spell 'ls-files --delete' option correctly in test descriptions
2013-06-30Merge branch 'ap/diff-ignore-blank-lines'Junio C Hamano
"git diff" learned a mode that ignores hunks whose change consists only of additions and removals of blank lines, which is the same as "diff -B" (ignore blank lines) of GNU diff. * ap/diff-ignore-blank-lines: diff: add --ignore-blank-lines option
2013-06-30Merge branch 'jk/submodule-subdirectory-ok'Junio C Hamano
Allow various subcommands of "git submodule" to be run not from the top of the working tree of the superproject. * jk/submodule-subdirectory-ok: submodule: drop the top-level requirement rev-parse: add --prefix option submodule: show full path in error message t7403: add missing && chaining t7403: modernize style t7401: make indentation consistent
2013-06-30test: spell 'ls-files --delete' option correctly in test descriptionsSZEDER Gábor
The option is spelled '--deleted'. Signed-off-by: SZEDER Gábor <szeder@ira.uka.de> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2013-06-28Merge branch 'nd/clone-connectivity-shortcut' (early part) into maintJunio C Hamano
Cloning with "git clone --depth N" while fetch.fsckobjects (or transfer.fsckobjects) is set to true did not tell the cut-off points of the shallow history to the process that validates the objects and the history received, causing the validation to fail. * 'nd/clone-connectivity-shortcut' (early part): fetch-pack: prepare updated shallow file before fetching the pack clone: let the user know when check_everything_connected is run
2013-06-27Merge branch 'ks/difftool-dir-diff-copy-fix' into maintJunio C Hamano
* ks/difftool-dir-diff-copy-fix: difftool --dir-diff: allow changing any clean working tree file
2013-06-27Merge branch 'fc/show-branch-in-rebase-am' into maintJunio C Hamano
* fc/show-branch-in-rebase-am: prompt: fix for simple rebase
2013-06-27Merge branch 'rs/commit-m-no-edit' into maintJunio C Hamano
* rs/commit-m-no-edit: commit: don't start editor if empty message is given with -m
2013-06-27Merge branch 'jc/strbuf-branchname-fix' into maintJunio C Hamano
* jc/strbuf-branchname-fix: strbuf_branchname(): do not double-expand @{-1}~22
2013-06-27Merge branch 'mk/combine-diff-context-horizon-fix' into maintJunio C Hamano
* mk/combine-diff-context-horizon-fix: combine-diff.c: Fix output when changes are exactly 3 lines apart
2013-06-27Merge branch 'kb/ancestry-path-threedots' into maintJunio C Hamano
* kb/ancestry-path-threedots: revision.c: treat A...B merge bases as if manually specified t6019: demonstrate --ancestry-path A...B breakage
2013-06-27Merge branch 'mh/fetch-into-shallow' into maintJunio C Hamano
* mh/fetch-into-shallow: t5500: add test for fetching with an unknown 'shallow' upload-pack: ignore 'shallow' lines with unknown obj-ids
2013-06-27Merge branch 'jh/checkout-auto-tracking' into maintJunio C Hamano
* jh/checkout-auto-tracking: glossary: Update and rephrase the definition of a remote-tracking branch branch.c: Validate tracking branches with refspecs instead of refs/remotes/* t9114.2: Don't use --track option against "svn-remote"-tracking branches t7201.24: Add refspec to keep --track working t3200.39: tracking setup should fail if there is no matching refspec. checkout: Use remote refspecs when DWIMming tracking branches t2024: Show failure to use refspec when DWIMming remote branch names t2024: Add tests verifying current DWIM behavior of 'git checkout <branch>'
2013-06-27Merge branch 'mt/send-email-cc-match-fix'Junio C Hamano
Logic used by git-send-email to suppress cc mishandled names that need RFC2047 quoting. * mt/send-email-cc-match-fix: send-email: sanitize author when writing From line send-email: add test for duplicate utf8 name
2013-06-27Merge branch 'jk/pull-into-dirty-unborn'Junio C Hamano
"git pull" into nothing trashed "local changes" that were in the index, and this avoids it. * jk/pull-into-dirty-unborn: pull: merge into unborn by fast-forwarding from empty tree pull: update unborn branch tip after index
2013-06-27Merge branch 'bc/checkout-tracking-name-plug-leak'Junio C Hamano
Plug a small leak in checkout. * bc/checkout-tracking-name-plug-leak: t/t9802: explicitly name the upstream branch to use as a base builtin/checkout.c: don't leak memory in check_tracking_name
2013-06-27Merge branch 'rr/rebase-stash-store'Junio C Hamano
Finishing touches for the "git rebase --autostash" feature introduced earlier. * rr/rebase-stash-store: rebase: use 'git stash store' to simplify logic stash: introduce 'git stash store' stash: simplify option parser for create stash doc: document short form -p in synopsis stash doc: add a warning about using create
2013-06-27rebase -i: handle fixup! fixup! in --autosquashAndrew Pimlott
In rebase -i --autosquash, ignore all "fixup! " or "squash! " after the first. This supports the case when a git commit --fixup/--squash referred to an earlier fixup/squash instead of the original commit (whether intentionally, as when the user expressly meant to note that the commit fixes an earlier fixup; or inadvertently, as when the user meant to refer to the original commit with :/msg; or out of laziness, as when the user could remember how to refer to the fixup but not the original). In the todo list, the full commit message is preserved, in case it provides useful cues to the user. A test helper set_cat_todo_editor is introduced to check this. Helped-by: Thomas Rast <trast@inf.ethz.ch> Helped-by: Junio C Hamano <gitster@pobox.com> Signed-off-by: Andrew Pimlott <andrew@pimlott.net> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2013-06-27am: replace uses of --resolved with --continueKevin Bracey
git am was previously modified to provide --continue for consistency with rebase, merge etc, and the documentation changed to showing --continue as the primary form. Complete the work by replacing remaining uses of --resolved by --continue, most notably in suggested command reminders. Signed-off-by: Kevin Bracey <kevin@bracey.fi> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2013-06-26Merge branch 'tr/maint-apply-non-git-patch-parsefix'Junio C Hamano
Fix for the codepath to parse patches that add new files, generated by programs other than Git. THis is an old breakage in v1.7.11 and will need to be merged down to the maintanance tracks. * tr/maint-apply-non-git-patch-parsefix: apply: carefully strdup a possibly-NULL name
2013-06-26Merge branch 'vl/typofix'Junio C Hamano
* vl/typofix: random typofixes (committed missing a 't', successful missing an 's')
2013-06-26Merge branch 'fg/submodule-non-ascii-path'Junio C Hamano
Many "git submodule" operations do not work on a submodule at a path whose name is not in ASCII. * fg/submodule-non-ascii-path: t7400: test of UTF-8 submodule names pass under Mac OS handle multibyte characters in name
2013-06-26git-prompt.sh: do not print duplicate clean color codeEduardo R. D'Avila
Do not print a duplicate clean color code when there is no other indicators other than the current branch in colored prompt. Acked-by: SZEDER Gábor <szeder@ira.uka.de> Signed-off-by: Eduardo R. D'Avila <erdavila@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2013-06-26t9903: remove redundant testsEduardo R. D'Avila
After refactoring __git_ps1_colorize_gitstring, codepaths for bash and zsh became mostly common and tests for bash and zsh became redundant. Remove tests for zsh. Keep one minimal test that stress the difference in codepaths for bash and zsh. Suggested-by: SZEDER Gábor <szeder@ira.uka.de> Signed-off-by: Eduardo R. D'Avila <erdavila@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2013-06-26t9903: add tests for git-prompt pcmodeEduardo R. D'Avila
git-prompt.sh lacks tests for PROMPT_COMMAND mode. Add tests for: * pcmode prompt without colors * pcmode prompt with colors for bash * pcmode prompt with colors for zsh Having these tests enables an upcoming refactor in a safe way. Signed-off-by: Eduardo R. D'Avila <erdavila@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2013-06-24Merge branch 'rr/am-quit-empty-then-abort-fix'Junio C Hamano
Recent "rebase --autostash" update made it impossible to recover with "git am --abort" from a repository where "git am" without mbox was run by mistake and then was killed with "^C". * rr/am-quit-empty-then-abort-fix: t/am: use test_path_is_missing() where appropriate am: handle stray $dotest directory
2013-06-24Merge branch 'rt/cherry-pick-continue-advice-in-status'Junio C Hamano
* rt/cherry-pick-continue-advice-in-status: wt-status: give better advice when cherry-pick is in progress
2013-06-24Merge branch 'dk/maint-t5150-dirname'Junio C Hamano
Fix a test script. * dk/maint-t5150-dirname: tests: allow sha1's as part of the path
2013-06-24Merge branch 'rr/rebase-sha1-by-string-query'Junio C Hamano
Allow various commit objects to be given to "git rebase" by ':/look for this string' syntax, e.g. "git rebase --onto ':/there'". * rr/rebase-sha1-by-string-query: rebase: use peel_committish() where appropriate sh-setup: add new peel_committish() helper t/rebase: add failing tests for a peculiar revision
2013-06-24Merge branch 'mm/rm-coalesce-errors'Junio C Hamano
Give a single message followed by list of paths from "git rm" to report multiple paths that cannot be removed. * mm/rm-coalesce-errors: rm: introduce advice.rmHints to shorten messages rm: better error message on failure for multiple files
2013-06-24bash prompt: use bash builtins to check stash stateSZEDER Gábor
When the environment variable $GIT_PS1_SHOWSTASHSTATE is set __git_ps1() checks the presence of stashes by running 'git rev-parse --verify refs/stash'. This command not only checks that the 'refs/stash' ref exists but also, well, verifies that it's a valid ref. However, we don't need to be that thorough for the bash prompt. We can omit that verification and only check whether 'refs/stash' exists or not. Since 'git pack-refs' never packs 'refs/stash', it's a matter of checking the existence of a ref file. Perform this check using only bash builtins to spare the overhead of fork()+exec()ing a git process. Also run 'git pack-refs --all' in the corresponding test to document that the prompt script depends on 'git pack-refs' not packing 'refs/stash' and to catch possible breakages should this behavior ever change. Signed-off-by: SZEDER Gábor <szeder@ira.uka.de>
2013-06-24bash prompt: combine 'git rev-parse' for detached headSZEDER Gábor
When describing a detached HEAD according to the $GIT_PS1_DESCRIBE environment variable fails, __git_ps1() now runs the '$(git rev-parse --short HEAD)' command substitution to get the abbreviated detached HEAD commit object name. This imposes the overhead of fork()ing a subshell and fork()+exec()ing a git process. Avoid this overhead by combining this command substitution with the "main" 'git rev-parse' execution for getting the path to the .git directory & co. This means that we'll look for the abbreviated commit object name even when it's not necessary, because we're on a branch or the detached HEAD can be described. It doesn't matter, however, because once 'git rev-parse' is up and running to fulfill all those other queries, the additional overhead of looking for the abbreviated commit object name is not measurable because it's lost in the noise. There is a caveat, however, when we are on an unborn branch, because in that case HEAD doesn't point to a valid commit, hence the query for the abbreviated commit object name fails. Therefore, '--short HEAD' must be the last options to 'git rev-parse' in order to get all the other necessary information for the prompt even on an unborn branch. Furthermore, in that case, and in that case only, 'git rev-parse' doesn't output the last line containing the abbreviated commit object name, obviously, so we have to take care to only parse it if 'git rev-parse' exited without any error. Although there are tests already excercising __git_ps1() on unborn branches, they all do so implicitly. Add a test that checks this explicitly. Signed-off-by: SZEDER Gábor <szeder@ira.uka.de>
2013-06-24bash prompt: print unique detached HEAD abbreviated object nameSZEDER Gábor
When describing a detached HEAD according to the $GIT_PS1_DESCRIBE environment variable fails, __git_ps1() runs 'cut -c1-7 .git/HEAD' to show the 7 hexdigits abbreviated commit object name in the prompt. Obviously, this neither respects core.abbrev nor produces a unique object name. Fix this by using 'git rev-parse --short HEAD' instead and adjust the corresponding test to use non-standard number of hexdigits. Signed-off-by: SZEDER Gábor <szeder@ira.uka.de>
2013-06-24bash prompt: add a test for symbolic link symbolic refsSZEDER Gábor
Signed-off-by: SZEDER Gábor <szeder@ira.uka.de>
2013-06-24completion, bash prompt: move __gitdir() tests to completion test suiteSZEDER Gábor
Currently __gitdir() is duplicated in the git completion and prompt scripts, while its tests are in the prompt test suite. This patch series is about to change __git_ps1() in a way that it won't need __gitdir() anymore and __gitdir() will be removed from the prompt script. So move all __gitdir() tests from the prompt test suite over to the completion test suite. Update the setup tests so that they perform only those steps that are necessary for each test suite. Signed-off-by: SZEDER Gábor <szeder@ira.uka.de>
2013-06-24Revert "Merge branch 'jg/status-config'"Junio C Hamano
This reverts commit 1a22bd31f0a5130ce6c934951a5526ceb774c2be, reversing changes made to 3e7a5b489e45ae8a3a0b222893d58b172d883136. It makes it impossible to "git commit" when status.short is set, and also "git status --porcelain" output is affected by status.branch.
2013-06-23bash prompt: use 'write_script' helper in interactive rebase testSZEDER Gábor
Helped-by: Jeff King <peff@peff.net> Signed-off-by: SZEDER Gábor <szeder@ira.uka.de>
2013-06-23bash prompt: fix redirection coding style in testsSZEDER Gábor
Use '>file' instead of '> file', in accordance with the coding guidelines. Signed-off-by: SZEDER Gábor <szeder@ira.uka.de>
2013-06-23Merge branch 'mz/rebase-tests'Junio C Hamano
* mz/rebase-tests: rebase topology tests: fix commit names on case-insensitive file systems tests: move test for rebase messages from t3400 to t3406 t3406: modernize style add tests for rebasing merged history add tests for rebasing root add tests for rebasing of empty commits add tests for rebasing with patch-equivalence present add simple tests of consistency across rebase types