aboutsummaryrefslogtreecommitdiff
path: root/t
Commit message (Collapse)AuthorAge
* t6042: Add a testcase where undetected rename causes silent file deletionElijah Newren2011-08-14
| | | | | | | | | There are cases where history should merge cleanly, and which current git does merge cleanly despite not detecting a rename; however the merge currently nukes files that should not be removed. Signed-off-by: Elijah Newren <newren@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
* t6042: Add a pair of cases where undetected renames cause issuesElijah Newren2011-08-14
| | | | | | | | | An undetected rename can cause a silent success where a conflict should have been detected, or can cause an erroneous conflict state where the merge should have been resolvable. Add testcases for both. Signed-off-by: Elijah Newren <newren@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
* t6042: Add failing testcase for rename/modify/add-source conflictElijah Newren2011-08-14
| | | | | | | | | | | If there is a cleanly resolvable rename/modify conflict AND there is a new file introduced on the renamed side of the merge whose name happens to match that of the source of the rename (but is otherwise unrelated to the rename), then git fails to cleanly resolve the merge despite the fact that the new file should not cause any problems. Signed-off-by: Elijah Newren <newren@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
* t6042: Add a testcase where git deletes an untracked fileElijah Newren2011-08-14
| | | | | | | | | | Current git will nuke an untracked file during a rename/delete conflict if (a) there is an untracked file whose name matches the source of a rename and (b) the merge is done in a certain direction. Add a simple testcase demonstrating this bug. Signed-off-by: Elijah Newren <newren@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
* Merge branch 'jk/maint-config-alias-fix' into maintJunio C Hamano2011-06-01
|\ | | | | | | | | | | | | | | * jk/maint-config-alias-fix: handle_options(): do not miscount how many arguments were used config: always parse GIT_CONFIG_PARAMETERS during git_config git_config: don't peek at global config_parameters config: make environment parsing routines static
| * handle_options(): do not miscount how many arguments were usedJunio C Hamano2011-05-24
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The handle_options() function advances the base of the argument array and returns the number of arguments it used. The caller in handle_alias() wants to reallocate the argv array it passes to this function, and attempts to do so by subtracting the returned value to compensate for the change handle_options() makes to the new_argv. But handle_options() did not correctly count when "-c <config=value>" is given, causing a wrong pointer to be passed to realloc(). Fix it by saving the original argv at the beginning of handle_options(), and return the difference between the final value of argv, which will relieve the places that move the array pointer from the additional burden of keeping track of "handled" counter. Noticed-by: Kazuki Tsujimoto Signed-off-by: Junio C Hamano <gitster@pobox.com> Signed-off-by: Jeff King <peff@peff.net> Signed-off-by: Junio C Hamano <gitster@pobox.com>
| * config: always parse GIT_CONFIG_PARAMETERS during git_configJeff King2011-05-24
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Previously we parsed GIT_CONFIG_PARAMETERS lazily into a linked list, and then checked that list during future invocations of git_config. However, that ignores the fact that the environment variable could change during our run (e.g., because we parse more "-c" as part of an alias). Instead, let's just re-parse the environment variable each time. It's generally not very big, and it's no more work than parsing the config files, anyway. As a bonus, we can ditch all of the linked list storage code entirely, making the code much simpler. The test unfortunately still does not pass because of an unrelated bug in handle_options. Signed-off-by: Jeff King <peff@peff.net> Signed-off-by: Junio C Hamano <gitster@pobox.com>
* | Merge branch 'ml/test-readme' into maintJunio C Hamano2011-05-31
|\ \ | | | | | | | | | | | | * ml/test-readme: t/README: unify documentation of test function args
| * | t/README: unify documentation of test function argsMathias Lafeldt2011-04-26
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Document all test function arguments in the same way. While at it, tweak the description of test_path_is_* (thanks to Junio), and correct some grammatical errors. Signed-off-by: Mathias Lafeldt <misfire@debugon.org> Signed-off-by: Junio C Hamano <gitster@pobox.com>
* | | Merge branch 'ab/i18n-fixup' into maintJunio C Hamano2011-05-31
|\ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * ab/i18n-fixup: (24 commits) i18n: use test_i18n{cmp,grep} in t7600, t7607, t7611 and t7811 i18n: use test_i18n{grep,cmp} in t7508 i18n: use test_i18ngrep in t7506 i18n: use test_i18ngrep and test_i18ncmp in t7502 i18n: use test_i18ngrep in t7501 i18n: use test_i18ncmp in t7500 i18n: use test_i18ngrep in t7201 i18n: use test_i18ncmp and test_i18ngrep in t7102 and t7110 i18n: use test_i18ncmp and test_i18ngrep in t5541, t6040, t6120, t7004, t7012 and t7060 i18n: use test_i18ncmp and test_i18ngrep in t3700, t4001 and t4014 i18n: use test_i18ncmp and test_i18ngrep in t3203, t3501 and t3507 i18n: use test_i18ngrep in t2020, t2204, t3030, and t3200 i18n: use test_i18ngrep in lib-httpd and t2019 i18n: do not overuse C_LOCALE_OUTPUT (grep) i18n: use test_i18ncmp in t1200 and t2200 i18n: .git file is not a human readable message (t5601) i18n: do not overuse C_LOCALE_OUTPUT i18n: mark init-db messages for translation i18n: mark checkout plural warning for translation i18n: mark checkout --detach messages for translation ...
| * | | i18n: use test_i18n{cmp,grep} in t7600, t7607, t7611 and t7811Junio C Hamano2011-04-14
| | | | | | | | | | | | | | | | Signed-off-by: Junio C Hamano <gitster@pobox.com>
| * | | i18n: use test_i18n{grep,cmp} in t7508Junio C Hamano2011-04-14
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Two tests looked for "[Uu]sage" in the output, but we cannot expect the l10n to use that phrase. Mark them with test_i18ngrep so that in later versions we can test truly localized versions with the same tests, not just GETTEXT_POISON that happens to keep the original string in the output. Merge a few tests that were artificially split into "do" and "test output under C_LOCALE_OUTPUT" in the original i18n patches back. Signed-off-by: Junio C Hamano <gitster@pobox.com>
| * | | i18n: use test_i18ngrep in t7506Junio C Hamano2011-04-14
| | | | | | | | | | | | | | | | Signed-off-by: Junio C Hamano <gitster@pobox.com>
| * | | i18n: use test_i18ngrep and test_i18ncmp in t7502Junio C Hamano2011-04-13
| | | | | | | | | | | | | | | | Signed-off-by: Junio C Hamano <gitster@pobox.com>
| * | | i18n: use test_i18ngrep in t7501Junio C Hamano2011-04-13
| | | | | | | | | | | | | | | | Signed-off-by: Junio C Hamano <gitster@pobox.com>
| * | | i18n: use test_i18ncmp in t7500Junio C Hamano2011-04-13
| | | | | | | | | | | | | | | | Signed-off-by: Junio C Hamano <gitster@pobox.com>
| * | | i18n: use test_i18ngrep in t7201Junio C Hamano2011-04-13
| | | | | | | | | | | | | | | | | | | | | | | | | | | | Some test were mistakenly disabled under GETTEXT_POISON as well, and they have been resurrected. Signed-off-by: Junio C Hamano <gitster@pobox.com>
| * | | i18n: use test_i18ncmp and test_i18ngrep in t7102 and t7110Junio C Hamano2011-04-13
| | | | | | | | | | | | | | | | Signed-off-by: Junio C Hamano <gitster@pobox.com>
| * | | i18n: use test_i18ncmp and test_i18ngrep in t5541, t6040, t6120, t7004, ↵Junio C Hamano2011-04-13
| | | | | | | | | | | | | | | | | | | | | | | | t7012 and t7060 Signed-off-by: Junio C Hamano <gitster@pobox.com>
| * | | i18n: use test_i18ncmp and test_i18ngrep in t3700, t4001 and t4014Junio C Hamano2011-04-13
| | | | | | | | | | | | | | | | Signed-off-by: Junio C Hamano <gitster@pobox.com>
| * | | i18n: use test_i18ncmp and test_i18ngrep in t3203, t3501 and t3507Junio C Hamano2011-04-13
| | | | | | | | | | | | | | | | Signed-off-by: Junio C Hamano <gitster@pobox.com>
| * | | i18n: use test_i18ngrep in t2020, t2204, t3030, and t3200Junio C Hamano2011-04-13
| | | | | | | | | | | | | | | | Signed-off-by: Junio C Hamano <gitster@pobox.com>
| * | | i18n: use test_i18ngrep in lib-httpd and t2019Junio C Hamano2011-04-13
| | | | | | | | | | | | | | | | Signed-off-by: Junio C Hamano <gitster@pobox.com>
| * | | i18n: do not overuse C_LOCALE_OUTPUT (grep)Junio C Hamano2011-04-13
| | | | | | | | | | | | | | | | | | | | | | | | | | | | Instead of skipping the whole test, introduce test_i18ngrep wrapper that pretends a successful result under GETTEXT_POISON build. Signed-off-by: Junio C Hamano <gitster@pobox.com>
| * | | i18n: use test_i18ncmp in t1200 and t2200Junio C Hamano2011-04-13
| | | | | | | | | | | | | | | | Signed-off-by: Junio C Hamano <gitster@pobox.com>
| * | | i18n: .git file is not a human readable message (t5601)Junio C Hamano2011-04-13
| | | | | | | | | | | | | | | | Signed-off-by: Junio C Hamano <gitster@pobox.com>
| * | | i18n: do not overuse C_LOCALE_OUTPUTJunio C Hamano2011-04-12
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | It is too coarse-grained way that led to artificial splitting of a logically single test case into "do" and "check only without poison". As the majority of check is done by comparing expected and actual output stored in a file with test_cmp anyway, just introduce test_i18ncmp that pretends the actual output matched the expected one when gettext-poison is in effect. Signed-off-by: Junio C Hamano <gitster@pobox.com>
| * | | i18n: mark init-db messages for translationÆvar Arnfjörð Bjarmason2011-04-12
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Mark the init-db messages that were added in v1.7.5-rc1~16^2 (init, clone: support --separate-git-dir for .git file) by Nguyễn Thái Ngọc Duy for translation. This requires splitting up the tests that the patch added so that certain parts of them can be skipped unless the C_LOCALE_OUTPUT prerequisite is satisfied. Signed-off-by: Ævar Arnfjörð Bjarmason <avarab@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
| * | | i18n: mark checkout plural warning for translationÆvar Arnfjörð Bjarmason2011-04-12
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Mark the "Warning: you are leaving %d commit(s) behind" message added in v1.7.5-rc0~74^2 (commit: give final warning when reattaching HEAD to leave commits behind) by Junio C Hamano for translation. This message requires the use of ngettext() features, and is the first message to use the Q_() wrapper around ngettext(). Signed-off-by: Ævar Arnfjörð Bjarmason <avarab@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
* | | | Merge branch 'jc/rename-degrade-cc-to-c' into maintJunio C Hamano2011-05-31
|\ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * jc/rename-degrade-cc-to-c: diffcore-rename: fall back to -C when -C -C busts the rename limit diffcore-rename: record filepair for rename src diffcore-rename: refactor "too many candidates" logic builtin/diff.c: remove duplicated call to diff_result_code()
| * | | | diffcore-rename: fall back to -C when -C -C busts the rename limitJunio C Hamano2011-03-22
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | When there are too many paths in the project, the number of rename source candidates "git diff -C -C" finds will exceed the rename detection limit, and no inexact rename detection is performed. We however could fall back to "git diff -C" if the number of modified paths is sufficiently small. Signed-off-by: Junio C Hamano <gitster@pobox.com>
* | | | | Merge branch 'jn/run-command-error-failure' into maintJunio C Hamano2011-05-29
|\ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * jn/run-command-error-failure: run-command: handle short writes and EINTR in die_child tests: check error message from run_command
| * | | | | tests: check error message from run_commandJonathan Nieder2011-04-20
| | |_|/ / | |/| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | In git versions starting at v1.7.5-rc0~29^2 until v1.7.5-rc3~2 (Revert "run-command: prettify -D_FORTIFY_SOURCE workaround", 2011-04-18) fixed it, the run_command facility would write a truncated error message when the command is present but cannot be executed for some other reason. For example, if I add a 'hello' command to git: $ echo 'echo hello' >git-hello $ chmod +x git-hello $ PATH=.:$PATH git hello hello and make it non-executable, this is what I normally get: $ chmod -x git-hello $ git hello fatal: cannot exec 'git-hello': Permission denied But with the problematic versions, we get disturbing output: $ PATH=.:$PATH git hello fatal: $ Add some tests to make sure it doesn't happen again. The hello-script used in these tests uses cat instead of echo because on Windows the bash spawned by git converts LF to CRLF in text written by echo while the bash running tests does not, causing the test to fail if "echo" is used. Thanks to Hannes for noticing. Signed-off-by: Jonathan Nieder <jrnieder@gmail.com> Improved-by: Johannes Sixt <j6t@kdbg.org> Signed-off-by: Junio C Hamano <gitster@pobox.com>
* | | | | Merge branch 'jm/maint-diff-words-with-sbe' into maintJunio C Hamano2011-05-26
|\ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | * jm/maint-diff-words-with-sbe: do not read beyond end of malloc'd buffer
| * | | | | do not read beyond end of malloc'd bufferJim Meyering2011-05-20
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | With diff.suppress-blank-empty=true, "git diff --word-diff" would output data that had been read from uninitialized heap memory. The problem was that fn_out_consume did not account for the possibility of a line with length 1, i.e., the empty context line that diff.suppress-blank-empty=true converts from " \n" to "\n". Since it assumed there would always be a prefix character (the space), it decremented "len" unconditionally, thus passing len=0 to emit_line, which would then blindly call emit_line_0 with len=-1 which would pass that value on to fwrite as SIZE_MAX. Boom. Signed-off-by: Jim Meyering <meyering@redhat.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
* | | | | | Merge branch 'jc/maint-pathspec-stdin-and-cmdline' into maintJunio C Hamano2011-05-26
|\ \ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | * jc/maint-pathspec-stdin-and-cmdline: setup_revisions(): take pathspec from command line and --stdin correctly
| * \ \ \ \ \ Merge branch 'jc/maint-1.7.4-pathspec-stdin-and-cmdline'Junio C Hamano2011-05-11
| |\ \ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Update the fix for 1.7.5 maintenance track. * jc/maint-1.7.4-pathspec-stdin-and-cmdline: setup_revisions(): take pathspec from command line and --stdin correctly
| | * \ \ \ \ \ Merge branch 'jc/maint-1.6.6-pathspec-stdin-and-cmdline'Junio C Hamano2011-05-11
| | |\ \ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Update the fix for 1.7.4 maintenance track. * jc/maint-1.6.6-pathspec-stdin-and-cmdline: setup_revisions(): take pathspec from command line and --stdin correctly
| | | * | | | | | setup_revisions(): take pathspec from command line and --stdin correctlyJunio C Hamano2011-05-11
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | When the command line has "--" disambiguator, we take the remainder of argv[] as "prune_data", but when --stdin is given at the same time, we need to append to the existing prune_data and end up attempting to realloc(3) it. That would not work. Fix it by consistently using append_prune_data() throughout the input processing. Also avoid counting the number of existing paths in the function over and over again. Signed-off-by: Junio C Hamano <gitster@pobox.com>
* | | | | | | | | Merge branch 'jk/cherry-pick-root-with-resolve' into maintJunio C Hamano2011-05-26
|\ \ \ \ \ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * jk/cherry-pick-root-with-resolve: t3503: test cherry picking and reverting root commits revert: allow reverting a root commit cherry-pick: handle root commits with external strategies
| * | | | | | | | | t3503: test cherry picking and reverting root commitsJeff King2011-05-16
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | We already tested cherry-picking a root commit, but only with the internal merge-recursive strategy. Let's also test the recently-allowed reverting of a root commit, as well as testing with external strategies (which until recently triggered a segfault). Signed-off-by: Jeff King <peff@peff.net> Signed-off-by: Junio C Hamano <gitster@pobox.com>
* | | | | | | | | | Merge branch 'jk/git-connection-deadlock-fix' into maintJunio C Hamano2011-05-26
|\ \ \ \ \ \ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * jk/git-connection-deadlock-fix: test core.gitproxy configuration send-pack: avoid deadlock on git:// push with failed pack-objects connect: let callers know if connection is a socket connect: treat generic proxy processes like ssh processes Conflicts: connect.c
| * | | | | | | | | | test core.gitproxy configurationJeff King2011-05-18
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This is just a basic sanity test to see whether core.gitproxy works at all. Until now, we were not testing anywhere. Signed-off-by: Jeff King <peff@peff.net> Signed-off-by: Junio C Hamano <gitster@pobox.com>
* | | | | | | | | | | Merge branch 'svn-fe-maint' of git://repo.or.cz/git/jrn into maintJunio C Hamano2011-05-26
|\ \ \ \ \ \ \ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * 'svn-fe-maint' of git://repo.or.cz/git/jrn: Revert "t0081 (line-buffer): add buffering tests"
| * | | | | | | | | | | Revert "t0081 (line-buffer): add buffering tests"Jonathan Nieder2011-03-30
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This (morally) reverts commit d280f68313eecb8b3838c70641a246382d5e5343, which added some tests that are a pain to maintain and are not likely to find bugs in git. Helped-by: Johannes Sixt <j6t@kdbg.org> Signed-off-by: Jonathan Nieder <jrnieder@gmail.com> Acked-by: Jeff King <peff@peff.net>
* | | | | | | | | | | | init/clone: remove short option -L and document --separate-git-dirNguyen Thai Ngoc Duy2011-05-25
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Signed-off-by: Nguyễn Thái Ngọc Duy <pclouds@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
* | | | | | | | | | | | git-svn: Fix git svn log --show-commitMichael J Gruber2011-05-20
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | git svn log --show-commit had no tests and, consequently, no attention by the author of b1b4755 (git-log: put space after commit mark, 2011-03-10) who kept git svn log working only without --show-commit. Introduce a test and fix it. Reported-by: Bernt Hansen <bernt@norang.ca> Signed-off-by: Michael J Gruber <git@drmicha.warpmail.net> Signed-off-by: Junio C Hamano <gitster@pobox.com>
* | | | | | | | | | | | Merge branch 'jc/t1506-shell-param-expansion-gotcha' into maintJunio C Hamano2011-05-16
|\ \ \ \ \ \ \ \ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * jc/t1506-shell-param-expansion-gotcha: t1507: avoid "${parameter<op>'word'}" inside double-quotes
| * | | | | | | | | | | | t1507: avoid "${parameter<op>'word'}" inside double-quotesJunio C Hamano2011-05-09
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Kacper Kornet noticed that a $variable in "word" in the above construct is not substituted by his pdksh. Modern POSIX compliant shells (e.g. dash, ksh, bash) all seem to interpret POSIX "2.6.2 Parameter Expansion" that says "word shall be subjected to tilde expansion, parameter expansion, command substitution, and arithmetic expansion" in ${parameter<op>word}, to mean that the word is expanded as if it appeared in dq pairs, so if the word were "'$variable'" (sans dq) it would expand to a single quote, the value of the $variable and then a single quote. Johannes Sixt reports that the behavior of quoting at the right of :- when the ${...:-...} expansion appears in double-quotes was debated recently at length at the Austin group. We can avoid this issue and future-proof the test by a slight rewrite. Helped-by: Johannes Sixt <j.sixt@viscovery.net> Signed-off-by: Junio C Hamano <gitster@pobox.com>
* | | | | | | | | | | | | Merge branch 'jc/fix-add-u-unmerged' into maintJunio C Hamano2011-05-16
|\ \ \ \ \ \ \ \ \ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * jc/fix-add-u-unmerged: Fix "add -u" that sometimes fails to resolve unmerged paths Conflicts: builtin/add.c