summaryrefslogtreecommitdiff
AgeCommit message (Collapse)AuthorFilesLines
2010-09-29t6036: Add a second testcase similar to the first but with content changesLibravatar Elijah Newren1-0/+76
c94736a (merge-recursive: don't segfault while handling rename clashes 2009-07-30) added t6036 with a testcase that involved dual renames and a criss-cross merge. Add a test that is nearly identical, but which also involves content modification -- a case git currently does not merge correctly. Signed-off-by: Elijah Newren <newren@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2010-09-29t6036: Test index and worktree state, not just that merge failsLibravatar Elijah Newren1-3/+21
c94736a (merge-recursive: don't segfault while handling rename clashes 2009-07-30) added this testcase with an interesting corner case test, which previously had cased git to segfault. This test ensures that the segfault does not return and that the merge correctly fails; just add some checks that verify the state of the index and worktree after the merge are correct. Signed-off-by: Elijah Newren <newren@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2010-09-29t6020: Add a testcase for modify/delete + directory/file conflictLibravatar Elijah Newren1-0/+47
Signed-off-by: Elijah Newren <newren@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2010-09-29t6020: Modernize style a bitLibravatar Elijah Newren1-15/+20
Signed-off-by: Elijah Newren <newren@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2010-09-29t6022: Add tests for rename/rename combined with D/F conflictsLibravatar Elijah Newren1-0/+79
Add tests where one file is renamed to two different paths in different sides of history, and where each of the new files matches the name of a directory from the opposite side of history. Include tests for both the case where the merge results in those directories not being cleanly removed, and where those directories are cleanly removed during the merge. Signed-off-by: Elijah Newren <newren@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2010-09-29t6022: Add paired rename+D/F conflict: (two/file, one/file) -> (one, two)Libravatar Elijah Newren1-0/+63
An interesting testcase is having two files each in their own subdirectory getting renamed to the toplevel at the directory pathname of the other. Questions arise as to whether the order of operations matters and whether the directories can correctly get out of the way and make room for the new files. Signed-off-by: Elijah Newren <newren@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2010-09-29t6022: Add tests with both rename source & dest involved in D/F conflictsLibravatar Elijah Newren1-0/+38
Having the source of a rename be involved in a directory/file conflict does not currently pose any difficulties to the current merge-recursive algorithm (in contrast to destinations of renames and D/F conflicts). However, combining the two seemed like good testcases to include for completeness. Signed-off-by: Elijah Newren <newren@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2010-09-29t6022: Add tests for reversing order of merges when D/F conflicts presentLibravatar Elijah Newren1-0/+58
When merging two branches with some path involved in a D/F conflict, the choice of which branch to merge into the other matters for (at least) two reasons: (1) whether the working copy has a directory full of files that is in the way of a file, or a file exists that is in the way of a directory of files, (2) when the directory full of files does not disappear due to the merge, what files at the same paths should be renamed to (e.g. filename~HEAD vs. filename~otherbranch). Add some tests that reverse the merge order of two other tests, and which verify the contents are as expected (namely, that the results are identical other than modified-for-uniqueness filenames involving branch names). Signed-off-by: Elijah Newren <newren@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2010-09-29t6022: Add test combinations of {content conflict?, D/F conflict remains?}Libravatar Elijah Newren1-0/+128
Add testing of the various ways that a renamed file to a path involved in a directory/file conflict may be involved in. This includes whether or not there are conflicts of the contents of the renamed file (if the file was modified on both sides of history), and whether the directory from the other side of the merge will disappear as a result of the merge or not. Signed-off-by: Elijah Newren <newren@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2010-09-29t6032: Add a test checking for excessive output from mergeLibravatar Elijah Newren1-0/+30
Previous D/F fixes I submitted (5a2580d and ae74548) had caused merge to become excessively spammy, which was fixed in 96ecac6 (merge-recursive: Avoid excessive output for and reprocessing of renames 2010-08-20). Add a new test to avoid repeating that mistake with my several upcoming changes. Signed-off-by: Elijah Newren <newren@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2010-09-29merge-recursive: Restructure showing how to chain more process_* functionsLibravatar Junio C Hamano1-3/+8
In 3734893 (merge-recursive: Fix D/F conflicts 2010-07-09), process_df_entry() was added to process_renames() and process_entry() but in a somewhat restrictive manner. Modify the code slightly to make it clearer how we could chain more such functions if necessary, and alter process_df_entry() to handle such chaining. Signed-off-by: Elijah Newren <newren@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2010-09-29t3030: Add a testcase for resolvable rename/add conflict with symlinksLibravatar Schalk, Ken1-1/+36
d5af510 (RE: [PATCH] Avoid rename/add conflict when contents are identical 2010-09-01) avoided erroring out in a rename/add conflict when the contents were identical. A simpler fix could have handled that particular testcase, but it would not correctly handle the case where a symlink is involved. Add another testcase using symlinks, to avoid breaking that case. Signed-off-by: Ken Schalk <ken.schalk@intel.com> Signed-off-by: Elijah Newren <newren@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2010-09-29Merge branch 'en/rename-d-f' into en/merge-recursiveLibravatar Junio C Hamano2-8/+74
* en/rename-d-f: merge-recursive: D/F conflicts where was_a_dir/file -> was_a_dir t3509: Add rename + D/F conflict testcase that recursive strategy fails
2010-09-18Git 1.7.3Libravatar Junio C Hamano3-14/+8
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2010-09-18Merge branch 'js/ls-files-x-doc'Libravatar Junio C Hamano1-5/+6
* js/ls-files-x-doc: ls-files documentation: reword for consistency git-ls-files.txt: clarify -x/--exclude option Conflicts: Documentation/git-ls-files.txt
2010-09-17git-rebase--interactive.sh: replace cut with ${v%% *}Libravatar Chris Johnsen1-1/+1
Some versions of cut do not cope well with lines that do not end in an LF. In this case, we can completely avoid cut by using the ${var%% *} parameter expansion (suggested by Brandon Casey). I found this problem when t3404's "avoid unnecessary reset" failed due to the "rebase -i" not avoiding updating the tested timestamp. On a Mac OS X 10.4.11 system: % printf '%s' 'foo bar' | /usr/bin/cut -d ' ' -f 1 cut: stdin: Illegal byte sequence Signed-off-by: Chris Johnsen <chris_johnsen@pobox.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2010-09-17t/t7300: workaround ancient touch by rearranging argumentsLibravatar Brandon Casey1-1/+1
The ancient touch on Solaris 7 thinks that a decimal number supplied as the first argument specifies a date_time to give to the files specified by the remaining arguments. In this case, it fails to parse '1' as a proper date_time and exits with a failure status. Workaround this flaw by rearranging the arguments supplied to touch so that a non-digit appears first and touch will not be confused. Signed-off-by: Brandon Casey <casey@nrlssc.navy.mil> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2010-09-16Merge branch 'bg/fix-t7003'Libravatar Junio C Hamano1-38/+41
* bg/fix-t7003: t7003: Use test_commit instead of custom function
2010-09-15ls-files documentation: reword for consistencyLibravatar Junio C Hamano1-4/+4
Similar to descriptions of other options, state what -x does in imperative mood. Start sentences for -X and --exclude-per-directory options in capital letters. Signed-off-by: Junio C Hamano <gitster@pobox.com>
2010-09-15git-ls-files.txt: clarify -x/--exclude optionLibravatar Jay Soffian1-2/+3
Since b5227d8, -x/--exclude does not apply to cached files. This is easy to miss unless you read the discussion in the EXCLUDE PATTERNS section. Clarify that the option applies to untracked files and direct the reader to EXCLUDE PATTERNS. Signed-off-by: Jay Soffian <jaysoffian@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2010-09-15Git 1.7.3 rc2Libravatar Junio C Hamano2-3/+9
2010-09-15Merge branch 'dr/maint-ls-tree-prefix-recursion-fix'Libravatar Junio C Hamano2-0/+11
* dr/maint-ls-tree-prefix-recursion-fix: ls-tree $di $dir: do not mistakenly recurse into directories
2010-09-15Merge branch 'os/fix-rebase-diff-no-prefix'Libravatar Junio C Hamano1-0/+1
* os/fix-rebase-diff-no-prefix: Add --src/dst-prefix to git-formt-patch in git-rebase.sh
2010-09-15Merge branch 'jl/fix-test'Libravatar Junio C Hamano35-491/+604
* jl/fix-test: t1020: Get rid of 'cd "$HERE"' at the start of each test t2016 (checkout -p): add missing && t1302 (core.repositoryversion): style tweaks t2105 (gitfile): add missing && t1450 (fsck): remove dangling objects tests: subshell indentation stylefix Several tests: cd inside subshell instead of around
2010-09-15Merge branch 'ch/filter-branch-deprecate-remap-to-ancestor'Libravatar Junio C Hamano3-14/+40
* ch/filter-branch-deprecate-remap-to-ancestor: filter-branch: retire --remap-to-ancestor
2010-09-15Merge branch 'ch/maint-cannot-create-bundle-error'Libravatar Junio C Hamano2-2/+11
* ch/maint-cannot-create-bundle-error: bundle: detect if bundle file cannot be created
2010-09-15Merge branch 'ks/recursive-rename-add-identical'Libravatar Junio C Hamano2-0/+41
* ks/recursive-rename-add-identical: RE: [PATCH] Avoid rename/add conflict when contents are identical
2010-09-15Merge git://repo.or.cz/git-guiLibravatar Junio C Hamano6-411/+454
* 'master' of git://repo.or.cz/git-gui: git-gui 0.13 git-gui: avoid mis-encoding the copyright message on Windows. git-gui: Update Swedish translation (521t). git-gui: ensure correct application termination in git-gui--askpass git-gui: handle textconv filter on Windows and in development git-gui: use shell to launch textconv filter in "blame" git-gui: display error launching blame as a message box. git-gui: Make usage statement visible on Windows.
2010-09-14git-gui 0.13Libravatar Pat Thoyts1-1/+1
Signed-off-by: Pat Thoyts <patthoyts@users.sourceforge.net>
2010-09-13git-gui: avoid mis-encoding the copyright message on Windows.Libravatar Pat Thoyts1-2/+2
On Windows the tcl script file will use the system encoding and attempting to convert the copyright mis-encodes the string. Instead, keep the message as ASCII and substitute in the correct unicode character when running. Signed-off-by: Pat Thoyts <patthoyts@users.sourceforge.net>
2010-09-13git-gui: Update Swedish translation (521t).Libravatar Peter Krefting1-399/+403
Signed-off-by: Peter Krefting <peter@softwolves.pp.se> Signed-off-by: Pat Thoyts <patthoyts@users.sourceforge.net>
2010-09-13t7003: Use test_commit instead of custom functionLibravatar Brian Gernhardt1-38/+41
t7003-filter-branch.sh had a make_commit() function that was identical to test_commit() in test-lib.sh except that it used tr to create a lowercase file name from the uppercase branch name instead of appending ".t". Not only is this unneeded code duplication, it also was something simply waiting to fail on case-insensitive file systems. So replace all uses of make_commit with test_commit. While we're editing the setup, chain it together with && so that failures early in the sequence don't get lost and add a commit graph. Signed-off-by: Brian Gernhardt <brian@gernhardtsoftware.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2010-09-12Merge branch 'maint'Libravatar Junio C Hamano2-63/+70
* maint: t3101: modernise style compat/nedmalloc: don't force NDEBUG on the rest of git Conflicts: Makefile
2010-09-12ls-tree $di $dir: do not mistakenly recurse into directoriesLibravatar Junio C Hamano2-0/+11
When applying two pathspecs, one of which is named as a prefix to the other, we mistakenly recursed into the shorter one. Noticed and fixed by David Reis. Signed-off-by: Junio C Hamano <gitster@pobox.com>
2010-09-12t3101: modernise styleLibravatar Junio C Hamano1-62/+64
Also add a few " &&" cascade that were missing. Signed-off-by: Junio C Hamano <gitster@pobox.com>
2010-09-12vcs-svn: Fix some printf format compiler warningsLibravatar Ramsay Jones3-5/+10
In particular, on systems that define uint32_t as an unsigned long, gcc complains as follows: CC vcs-svn/fast_export.o vcs-svn/fast_export.c: In function `fast_export_modify': vcs-svn/fast_export.c:28: warning: unsigned int format, uint32_t arg (arg 2) vcs-svn/fast_export.c:28: warning: int format, uint32_t arg (arg 3) vcs-svn/fast_export.c: In function `fast_export_commit': vcs-svn/fast_export.c:42: warning: int format, uint32_t arg (arg 5) vcs-svn/fast_export.c:62: warning: int format, uint32_t arg (arg 2) vcs-svn/fast_export.c: In function `fast_export_blob': vcs-svn/fast_export.c:72: warning: int format, uint32_t arg (arg 2) vcs-svn/fast_export.c:72: warning: int format, uint32_t arg (arg 3) CC vcs-svn/svndump.o vcs-svn/svndump.c: In function `svndump_read': vcs-svn/svndump.c:260: warning: int format, uint32_t arg (arg 3) In order to suppress the warnings we use the C99 format specifier macros PRIo32 and PRIu32 from <inttypes.h>. Signed-off-by: Ramsay Jones <ramsay@ramsay1.demon.co.uk> Acked-by: Jonathan Nieder <jrnieder@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2010-09-11compat/nedmalloc: don't force NDEBUG on the rest of gitLibravatar René Scharfe1-1/+6
Define the nedmalloc feature configuration macros for nedmalloc.o, only. This keeps assert(3) working for the rest of the git source; it was turned off for nedmalloc users before by defining NDEBUG globally. Also remove -DUSE_NED_ALLOCATOR as this macro isn't used anywhere. Signed-off-by: Rene Scharfe <rene.scharfe@lsrfire.ath.cx> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2010-09-10Git 1.7.3 rc1Libravatar Junio C Hamano1-1/+1
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2010-09-10Merge branch 'np/relnotes-in-subdir'Libravatar Junio C Hamano111-108/+108
* np/relnotes-in-subdir: install-webdoc: keep installed RelNotes-*.txt Documentation: move RelNotes into a directory of their own
2010-09-10Prepare for 1.7.3 rc1Libravatar Junio C Hamano1-2/+10
2010-09-10Merge branch 'maint'Libravatar Junio C Hamano1-2/+3
* maint: config.txt: fix placement of diff.noprefix
2010-09-10config.txt: fix placement of diff.noprefixLibravatar Mark Lodato1-2/+3
In git-config(1), diff.noprefix was placed in between diff.mnemonicprefix and the list of mnemonic prefixes, which is obviously incorrect and very confusing to readers. Now, it is located after the end of the explanation of mnemonicprefix, which makes much more sense. Signed-off-by: Mark Lodato <lodatom@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2010-09-10t/t4018: avoid two unnecessary sub-shell invocationsLibravatar Brandon Casey1-4/+4
Signed-off-by: Brandon Casey <casey@nrlssc.navy.mil> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2010-09-09Merge branch 'maint'Libravatar Junio C Hamano2-4/+6
* maint: xdiff-interface.c: always trim trailing space from xfuncname matches diff.c: call regfree to free memory allocated by regcomp when necessary
2010-09-09t/t4018: test whether the word_regex patterns compileLibravatar Brandon Casey1-0/+5
Previously (e3bf5e43), a test was added to test whether the builtin xfuncname regular expressions could be compiled without error by regcomp. Let's do the same for the word_regex patterns. This should help catch any cross-platform incompatibilities that exist between the pattern creator's system and the various platforms that the test suite is commonly run on. Signed-off-by: Brandon Casey <casey@nrlssc.navy.mil> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2010-09-09xdiff-interface.c: always trim trailing space from xfuncname matchesLibravatar Brandon Casey1-3/+2
Generally, trailing space is removed from the string matched by the xfuncname patterns. The exception is when the matched string exceeds the length of the fixed-size buffer that it will be copied in to. But, a string that exceeds the buffer can still contain trailing space in the portion of the string that will be copied into the buffer. So, simplify this code slightly, and just perform the trailing space removal always. Signed-off-by: Brandon Casey <casey@nrlssc.navy.mil> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2010-09-09diff.c: call regfree to free memory allocated by regcomp when necessaryLibravatar Brandon Casey1-1/+4
Signed-off-by: Brandon Casey <casey@nrlssc.navy.mil> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2010-09-09t/t5510-fetch.sh: improve testing with explicit URL and merge specLibravatar Brandon Casey1-2/+28
Commit 6106ce46 introduced a test to demonstrate fetch's failure to retrieve any objects or update FETCH_HEAD when it was supplied a repository URL and the current branch had a configured merge spec. This commit expands the original test based on comments from Junio Hamano. In addition to actually verifying that the fetch updates FETCH_HEAD correctly, and does not update the current branch, two more tests are added to ensure that the merge configuration is ignored even when the supplied URL matches the URL of the remote configured for the branch. Signed-off-by: Brandon Casey <casey@nrlssc.navy.mil> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2010-09-09builtin/fetch.c: comment that branch->remote_name is usable when has_mergeLibravatar Brandon Casey1-0/+3
Save future readers the trouble of tracing code to determine that the two uses of branch->remote_name are safe when has_merge is set, by adding a comment explaining that it is so. Signed-off-by: Brandon Casey <casey@nrlssc.navy.mil> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2010-09-09Makefile: use compat regex on IRIX 6.5Libravatar Brandon Casey1-0/+2
The IRIX 6.5 regex.h header file defines REG_STARTEND, but the feature does not appear to work. Since REG_STARTEND is required for proper functioning of git-grep, set NO_REGEX and use the alternative regex libraries in compat/ Signed-off-by: Brandon Casey <casey@nrlssc.navy.mil> Signed-off-by: Junio C Hamano <gitster@pobox.com>