summaryrefslogtreecommitdiff
path: root/t
AgeCommit message (Collapse)AuthorFilesLines
2007-11-28Revert "t5516: test update of local refs on push"Libravatar Jeff King1-28/+0
This reverts commit 09fba7a59d38d1cafaf33eadaf1d409c4113b30c. These tests are superseded by the ones in t5404 (added in 6fa92bf3 and 8736a848), which are more extensive and better organized. Signed-off-by: Jeff King <peff@peff.net> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2007-11-24t4119: correct overeager war-on-whitespaceLibravatar Junio C Hamano1-1/+1
Earlier a6080a0a44d5ead84db3dabbbc80e82df838533d (War on whitespace) dropped a necessary trailing whitespace from the test vector.
2007-11-24Merge branch 'jk/send-pack'Libravatar Junio C Hamano5-0/+399
* jk/send-pack: (24 commits) send-pack: cluster ref status reporting send-pack: fix "everything up-to-date" message send-pack: tighten remote error reporting make "find_ref_by_name" a public function Fix warning about bitfield in struct ref send-pack: assign remote errors to each ref send-pack: check ref->status before updating tracking refs send-pack: track errors for each ref git-push: add documentation for the newly added --mirror mode Add tests for git push'es mirror mode Update the tracking references only if they were succesfully updated on remote Add a test checking if send-pack updated local tracking branches correctly git-push: plumb in --mirror mode Teach send-pack a mirror mode send-pack: segfault fix on forced push Reteach builtin-ls-remote to understand remotes send-pack: require --verbose to show update of tracking refs receive-pack: don't mention successful updates more terse push output Build in ls-remote ...
2007-11-24Merge branch 'js/mingw-fallouts'Libravatar Junio C Hamano4-22/+49
* js/mingw-fallouts: fetch-pack: Prepare for a side-band demultiplexer in a thread. rehabilitate some t5302 tests on 32-bit off_t machines Allow ETC_GITCONFIG to be a relative path. Introduce git_etc_gitconfig() that encapsulates access of ETC_GITCONFIG. Allow a relative builtin template directory. Close files opened by lock_file() before unlinking. builtin run_command: do not exit with -1. Move #include <sys/select.h> and <sys/ioctl.h> to git-compat-util.h. Use is_absolute_path() in sha1_file.c. Skip t3902-quoted.sh if the file system does not support funny names. t5302-pack-index: Skip tests of 64-bit offsets if necessary. t7501-commit.sh: Not all seds understand option -i t5300-pack-object.sh: Split the big verify-pack test into smaller parts.
2007-11-24Merge branch 'mh/rebase-skip-hard'Libravatar Junio C Hamano1-2/+0
* mh/rebase-skip-hard: Do git reset --hard HEAD when using git rebase --skip
2007-11-24Merge branch 'cc/bisect'Libravatar Junio C Hamano1-1/+38
* cc/bisect: Bisect reset: do nothing when not bisecting. Bisect: use "$GIT_DIR/BISECT_NAMES" to check if we are bisecting. Bisect visualize: use "for-each-ref" to list all good refs. git-bisect: modernize branch shuffling hack git-bisect: use update-ref to mark good/bad commits git-bisect: war on "sed" Bisect reset: remove bisect refs that may have been packed.
2007-11-22Make test scripts executable.Libravatar Junio C Hamano1-0/+0
2007-11-22Merge branch 'maint'Libravatar Junio C Hamano3-0/+13
* maint: Make test scripts executable. bundle create: keep symbolic refs' names instead of resolving them
2007-11-22Make test scripts executable.Libravatar Junio C Hamano2-0/+0
2007-11-22rebase -i: move help to end of todo fileLibravatar Johannes Schindelin1-1/+2
[PATCH] rebase -i: move help to end of todo file Many editors start in the first line, so the 9-line help text was an annoyance. So move it to the end. Requested by Junio. While at it, add a hint how to abort the rebase. Signed-off-by: Johannes Schindelin <johannes.schindelin@gmx.de> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2007-11-22bundle create: keep symbolic refs' names instead of resolving themLibravatar Johannes Schindelin1-0/+13
When creating a bundle, symbolic refs used to be resolved to the non-symbolic refs they point to before being written to the list of contained refs. I.e. "git bundle create a1.bundle HEAD master" would show something like 388afe7881b33102fada216dd07806728773c011 refs/heads/master 388afe7881b33102fada216dd07806728773c011 refs/heads/master instead of 388afe7881b33102fada216dd07806728773c011 HEAD 388afe7881b33102fada216dd07806728773c011 refs/heads/master Introduce a special handling so that the symbolic refs are listed with the names passed on the command line. Noticed by Santi Béjar. Signed-off-by: Johannes Schindelin <johannes.schindelin@gmx.de> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2007-11-22Merge git://git.bogomips.org/git-svnLibravatar Junio C Hamano2-0/+369
* git://git.bogomips.org/git-svn: git-svn: allow `info' command to work offline git-svn: info --url [path] git-svn info: implement info command git-svn: extract reusable code into utility functions t9106: fix a race condition that caused svn to miss modifications
2007-11-21Fix "quote" misconversion for rewrite diff output.Libravatar Junio C Hamano1-0/+26
663af3422a648e87945e4d8c0cc3e13671f2bbde (Full rework of quote_c_style and write_name_quoted.) mistakenly used puts() when writing out a fixed string when it did not want to add a terminating LF. Signed-off-by: Junio C Hamano <gitster@pobox.com>
2007-11-21git-svn: info --url [path]Libravatar David D. Kilzer1-0/+93
Return the svn URL for the given path, or return the svn repository URL if no path is given. Added 18 tests to t/t9119-git-svn-info.sh. Signed-off-by: David D. Kilzer <ddkilzer@kilzer.net> Acked-by: Eric Wong <normalperson@yhbt.net>
2007-11-21git-svn info: implement info commandLibravatar David D. Kilzer1-0/+275
Implement "git-svn info" for files and directories based on the "svn info" command. Note that the -r/--revision argument is not supported yet. Added 18 tests in t/t9119-git-svn-info.sh. [ew: small fix to work without arguments on all working directories] Signed-off-by: David D. Kilzer <ddkilzer@kilzer.net> Acked-by: Eric Wong <normalperson@yhbt.net>
2007-11-21t9106: fix a race condition that caused svn to miss modificationsLibravatar Eric Wong1-0/+1
carbonated beverage noticed this test was occasionally failing. Signed-off-by: Eric Wong <normalperson@yhbt.net>
2007-11-20Bisect reset: do nothing when not bisecting.Libravatar Christian Couder1-1/+26
Before this patch, using "git bisect reset" when not bisecting did a "git checkout master" for no good reason. This also happened using "git bisect replay" when not bisecting because "bisect_replay" starts by calling "bisect_reset". Signed-off-by: Christian Couder <chriscool@tuxfamily.org> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2007-11-19git-send-email: show all headers when sending mailLibravatar David D. Kilzer1-0/+37
As a git newbie, it was confusing to set an In-Reply-To header but then not see it printed when the git-send-email command was run. This patch prints all headers that would be sent to sendmail or an SMTP server instead of only printing From, Subject, Cc, To. It also removes the now-extraneous Date header after the "Log says" line. Added test to t/t9001-send-email.sh. Signed-off-by: David D. Kilzer <ddkilzer@kilzer.net> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2007-11-18Merge branch 'lt/rev-list-gitlink'Libravatar Junio C Hamano1-0/+42
* lt/rev-list-gitlink: Fix rev-list when showing objects involving submodules
2007-11-18Merge branch 'ds/checkout-upper'Libravatar Junio C Hamano1-0/+82
* ds/checkout-upper: git-checkout: Test for relative path use. git-checkout: Support relative paths containing "..".
2007-11-17Merge git://git.bogomips.org/git-svnLibravatar Junio C Hamano2-0/+135
* git://git.bogomips.org/git-svn: git-svn: Fix a typo and add a comma in an error message in git-svn git-svn log: handle unreachable revisions like "svn log" git-svn log: include commit log for the smallest revision in a range git-svn log: fix ascending revision ranges git-svn's dcommit must use subversion's config git-svn: add tests for command-line usage of init and clone commands
2007-11-17git-svn log: handle unreachable revisions like "svn log"Libravatar David D Kilzer1-0/+66
When unreachable revisions are given to "svn log", it displays all commit logs in the given range that exist in the current tree. (If no commit logs are found in the current tree, it simply prints a single commit log separator.) This patch makes "git-svn log" behave the same way. Ten tests added to t/t9116-git-svn-log.sh. Signed-off-by: David D Kilzer <ddkilzer@kilzer.net> Acked-by: Eric Wong <normalperson@yhbt.net>
2007-11-17git-svn log: include commit log for the smallest revision in a rangeLibravatar David D Kilzer1-4/+4
The "svn log -rM:N" command shows commit logs inclusive in the range [M,N]. Previously "git-svn log" always excluded the commit log for the smallest revision in a range, whether the range was ascending or descending. With this patch, the smallest revision in a range is always shown. Updated tests for ascending and descending revision ranges. Signed-off-by: David D Kilzer <ddkilzer@kilzer.net> Acked-by: Eric Wong <normalperson@yhbt.net>
2007-11-17git-svn log: fix ascending revision rangesLibravatar David D Kilzer1-0/+14
Fixed typo in Git::SVN::Log::git_svn_log_cmd(). Previously a command like "git-svn log -r1:4" would only show a commit log separator. Added tests for ascending and descending revision ranges. Signed-off-by: David D Kilzer <ddkilzer@kilzer.net> Acked-by: Eric Wong <normalperson@yhbt.net>
2007-11-17git-svn: add tests for command-line usage of init and clone commandsLibravatar Eric Wong1-0/+55
Some patches broke these commands in certain cases and were only caught by manual testing. Signed-off-by: Eric Wong <normalperson@yhbt.net>
2007-11-17send-pack: assign remote errors to each refLibravatar Jeff King1-0/+24
This lets us show remote errors (e.g., a denied hook) along with the usual push output. There is a slightly clever optimization in receive_status that bears explanation. We need to correlate the returned status and our ref objects, which naively could be an O(m*n) operation. However, since the current implementation of receive-pack returns the errors to us in the same order that we sent them, we optimistically look for the next ref to be looked up to come after the last one we have found. So it should be an O(m+n) merge if the receive-pack behavior holds, but we fall back to a correct but slower behavior if it should change. Signed-off-by: Jeff King <peff@peff.net> Acked-by: Daniel Barkalow <barkalow@iabervon.org> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2007-11-17send-pack: check ref->status before updating tracking refsLibravatar Jeff King1-0/+5
Previously, we manually checked the 'NONE' and 'UPTODATE' conditions. Now that we have ref->status, we can easily say "only update if we pushed successfully". This adds a test for and fixes a regression introduced in ed31df31 where deleted refs did not have their tracking branches removed. This was due to a bogus per-ref error test that is superseded by the more accurate ref->status flag. Signed-off-by: Jeff King <peff@peff.net> Completely-Acked-By: Alex "Sleepy" Riesen <raa.lkml@gmail.com> Acked-by: Daniel Barkalow <barkalow@iabervon.org> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2007-11-17send-pack: track errors for each refLibravatar Jeff King1-3/+11
Instead of keeping the 'ret' variable, we instead have a status flag for each ref that tracks what happened to it. We then print the ref status after all of the refs have been examined. This paves the way for three improvements: - updating tracking refs only for non-error refs - incorporating remote rejection into the printed status - printing errors in a different order than we processed (e.g., consolidating non-ff errors near the end with a special message) Signed-off-by: Jeff King <peff@peff.net> Acked-by: Alex Riesen <raa.lkml@gmail.com> Acked-by: Daniel Barkalow <barkalow@iabervon.org> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2007-11-17Fix and improve t7004 (git-tag tests)Libravatar Mike Hommey1-2/+12
Brown paper bag fix to avoid using non portable sed syntax. The test by itself didn't catch what it was supposed to, anyways. The new test first checks if git-tag correctly errors out when the user exited the editor without editing the file. Then it checks if what the user was presented in the editor was any useful, which we define as the following: * It begins with a single blank line, where the invoked editor would typically place the editing curser at, so that the user can immediately start typing; * It has some instruction but that comes after that initial blank line, all lines prefixed with "#". We specifically do not check for the wording of this instruction. * And it has nothing else, as the expected behaviour is "Hey you did not leave any message". Signed-off-by: Mike Hommey <mh@glandium.org> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2007-11-16Merge branch 'maint'Libravatar Junio C Hamano1-1/+1
* maint: Update draft release notes for 1.5.3.6 Fix per-directory exclude handing for "git add" core.excludesfile clean-up Fix t9101 test failure caused by Subversion "auto-props" git-send-email: add charset header if we add encoded 'From'
2007-11-16Fix per-directory exclude handing for "git add"Libravatar Junio C Hamano1-0/+24
In "dir_struct", each exclusion element in the exclusion stack records a base string (pointer to the beginning with length) so that we can tell where it came from, but this pointer is just pointing at the parameter that is given by the caller to the push_exclude_per_directory() function. While read_directory_recursive() runs, calls to excluded() makes use the data in the exclusion elements, including this base string. The caller of read_directory_recursive() is not supposed to free the buffer it gave to push_exclude_per_directory() earlier, until it returns. The test case Bruce Stephens gave in the mailing list discussion was simplified and added to the t3700 test. Signed-off-by: Junio C Hamano <gitster@pobox.com>
2007-11-16Fix t9101 test failure caused by Subversion "auto-props"Libravatar Wincent Colaiuta1-1/+1
If a user has an "auto-prop" in his/her ~/.subversion/config file for automatically setting the svn:keyword Id property on all ".c" files (a reasonably common configuration in the Subversion world) then one of the "svn propset" operations in the very first test would become a no-op, which in turn would make the next commit a no-op. This then caused the 25th test ('test propget') to fail because it expects a certain number of commits to have taken place but the actual number of commits was off by one. Björn Steinbrink identified the "auto-prop" feature as the cause of the failure. This patch avoids it by passing the "--no-auto-prop" flag to "svn import" when setting up the test repository, thus ensuring that the "svn propset" operation is no longer a no-op, regardless of the users' settings in their config. Signed-off-by: Wincent Colaiuta <win@wincent.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2007-11-16Bisect reset: remove bisect refs that may have been packed.Libravatar Christian Couder1-0/+12
If refs were ever packed in the middle of bisection, the bisect refs were not removed from the "packed-refs" file. This patch fixes this problem by using "git update-ref -d $ref $hash" in "bisect_clean_state". Signed-off-by: Christian Couder <chriscool@tuxfamily.org> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2007-11-16Fix per-directory exclude handing for "git add"Libravatar Junio C Hamano1-0/+24
In "dir_struct", each exclusion element in the exclusion stack records a base string (pointer to the beginning with length) so that we can tell where it came from, but this pointer is just pointing at the parameter that is given by the caller to the push_exclude_per_directory() function. While read_directory_recursive() runs, calls to excluded() makes use the data in the exclusion elements, including this base string. The caller of read_directory_recursive() is not supposed to free the buffer it gave to push_exclude_per_directory() earlier, until it returns. The test case Bruce Stephens gave in the mailing list discussion was simplified and added to the t3700 test. Signed-off-by: Junio C Hamano <gitster@pobox.com>
2007-11-15rehabilitate some t5302 tests on 32-bit off_t machinesLibravatar Nicolas Pitre1-7/+2
Commit 8ed2fca458d085f12c3c6808ef4ddab6aa40ef14 was a bit draconian in skipping certain tests which should be perfectly valid even on platform with a 32-bit off_t. Signed-off-by: Nicolas Pitre <nico@cam.org> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2007-11-14Skip t3902-quoted.sh if the file system does not support funny names.Libravatar Johannes Sixt1-0/+7
Signed-off-by: Johannes Sixt <johannes.sixt@telecom.at> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2007-11-14t5302-pack-index: Skip tests of 64-bit offsets if necessary.Libravatar Johannes Sixt1-2/+23
There are platforms where off_t is not 64 bits wide. In this case many tests are doomed to fail. Let's skip them. Signed-off-by: Johannes Sixt <johannes.sixt@telecom.at> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2007-11-14t7501-commit.sh: Not all seds understand option -iLibravatar Johannes Sixt1-2/+4
Use mv instead. Signed-off-by: Johannes Sixt <johannes.sixt@telecom.at> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2007-11-14t5300-pack-object.sh: Split the big verify-pack test into smaller parts.Libravatar Johannes Sixt1-16/+18
This makes it easier to spot which of the tests failed. Signed-off-by: Johannes Sixt <johannes.sixt@telecom.at> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2007-11-14Merge branch 'sp/fetch-fix'Libravatar Junio C Hamano1-0/+33
* sp/fetch-fix: git-fetch: avoid local fetching from alternate (again) rev-list: Introduce --quiet to avoid /dev/null redirects run-command: Support sending stderr to /dev/null git-fetch: Always fetch tags if the object they reference exists
2007-11-14Merge branch 'bs/maint-commit-options'Libravatar Junio C Hamano1-0/+10
* bs/maint-commit-options: git-commit: Add tests for invalid usage of -a/--interactive with paths git-commit.sh: Fix usage checks regarding paths given when they do not make sense
2007-11-14Merge branch 'rv/maint-index-commit'Libravatar Junio C Hamano1-0/+32
* rv/maint-index-commit: Make GIT_INDEX_FILE apply to git-commit
2007-11-14Merge branch 'bs/maint-t7005'Libravatar Junio C Hamano1-3/+2
* bs/maint-t7005: t7005-editor.sh: Don't invoke real vi when it is in GIT_EXEC_PATH
2007-11-14Merge branch 'jc/maint-add-sync-stat'Libravatar Junio C Hamano1-2/+28
* jc/maint-add-sync-stat: t2200: test more cases of "add -u" git-add: make the entry stat-clean after re-adding the same contents ce_match_stat, run_diff_files: use symbolic constants for readability Conflicts: builtin-add.c
2007-11-14Merge branch 'mh/retag'Libravatar Junio C Hamano1-0/+16
* mh/retag: Add tests for git tag Reuse previous annotation when overwriting a tag
2007-11-14Merge branch 'bg/format-patch-N'Libravatar Junio C Hamano1-0/+106
* bg/format-patch-N: Rearrange git-format-patch synopsis to improve clarity. format-patch: Test --[no-]numbered and format.numbered format-patch: Add configuration and off switch for --numbered
2007-11-14Merge branch 'js/rebase-detached'Libravatar Junio C Hamano2-1/+23
* js/rebase-detached: rebase: fix "rebase --continue" breakage rebase: operate on a detached HEAD
2007-11-14Fix rev-list when showing objects involving submodulesLibravatar Linus Torvalds1-0/+42
The function mark_tree_uninteresting() assumed that the tree entries are blob when they are not trees. This is not so. Since we do not traverse into submodules (yet), the gitlinks should be ignored. In general, we should try to start moving away from using the "S_ISLNK()" like things for internal git state. It was a mistake to just assume the numbers all were same across all systems in the first place. This implementation converts to the "object_type", and then uses a case statement. Noticed by Ilari on IRC. Test script taken from an earlier version by Dscho. Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2007-11-14Merge branch 'maint'Libravatar Junio C Hamano2-1/+12
* maint: git-clean: honor core.excludesfile Documentation: Fix man page breakage with DocBook XSL v1.72 git-remote.txt: fix typo core-tutorial.txt: Fix argument mistake in an example. replace reference to git-rm with git-reset in git-commit doc Grammar fixes for gitattributes documentation Don't allow fast-import tree delta chains to exceed maximum depth revert/cherry-pick: allow starting from dirty work tree. t/t3404: fix test for a bogus todo file. Conflicts: fast-import.c
2007-11-14Merge branch 'aw/mirror-push' into jk/send-packLibravatar Junio C Hamano2-0/+270
* aw/mirror-push: git-push: add documentation for the newly added --mirror mode Add tests for git push'es mirror mode git-push: plumb in --mirror mode Teach send-pack a mirror mode send-pack: segfault fix on forced push send-pack: require --verbose to show update of tracking refs receive-pack: don't mention successful updates more terse push output Conflicts: transport.c transport.h