path: root/t/
AgeCommit message (Collapse)Author
2020-03-10pull: warn if the user didn't say whether to rebase or to mergeAlex Henrie
Often novice Git users forget to say "pull --rebase" and end up with an unnecessary merge from upstream. What they usually want is either "pull --rebase" in the simpler cases, or "pull --ff-only" to update the copy of main integration branches, and rebase their work separately. The pull.rebase configuration variable exists to help them in the simpler cases, but there is no mechanism to make these users aware of it. Issue a warning message when no --[no-]rebase option from the command line and no pull.rebase configuration variable is given. This will inconvenience those who never want to "pull --rebase", who haven't had to do anything special, but the cost of the inconvenience is paid only once per user, which should be a reasonable cost to help a number of new users. Signed-off-by: Alex Henrie <> Signed-off-by: Junio C Hamano <>
2015-05-18pull: make pull.ff=true override merge.ffPaul Tan
Since b814da8 (pull: add pull.ff configuration, 2014-01-15), running git-pull with the configuration pull.ff=false or pull.ff=only is equivalent to passing --no-ff and --ff-only to git-merge. However, if pull.ff=true, no switch is passed to git-merge. This leads to the confusing behavior where pull.ff=false or pull.ff=only is able to override merge.ff, while pull.ff=true is unable to. Fix this by adding the --ff switch if pull.ff=true, and add a test to catch future regressions. Furthermore, clarify in the documentation that pull.ff overrides merge.ff. Signed-off-by: Paul Tan <> Reviewed-by: Johannes Schindelin <> Signed-off-by: Junio C Hamano <>
2014-01-16pull: add pull.ff configurationDavid Aguilar
Add a `pull.ff` configuration option that is analogous to the `merge.ff` option. This allows us to control the fast-forward behavior for pull-initiated merges only. Signed-off-by: David Aguilar <> Signed-off-by: Junio C Hamano <>
2013-07-29many small typofixesOndřej Bílka
Signed-off-by: Ondřej Bílka <> Reviewed-by: Marc Branchaud <> Signed-off-by: Junio C Hamano <>
2013-04-12Correct common spelling mistakes in comments and testsStefano Lattarini
Most of these were found using Lucas De Marchi's codespell tool. Signed-off-by: Stefano Lattarini <> Signed-off-by: Jonathan Nieder <> Acked-by: Matthieu Moy <> Signed-off-by: Junio C Hamano <>
2010-10-06t7601 (merge-pull-config): add missing &&Elijah Newren
Also prefix several relevant git merge commands with 'test_must_fail' to keep the tests passing. Acked-by: Ævar Arnfjörð Bjarmason <> Reviewed-by: Jonathan Nieder <> Signed-off-by: Elijah Newren <> Signed-off-by: Junio C Hamano <>
2008-09-03tests: use "git xyzzy" form (t7200 - t9001)Nanako Shiraishi
Converts tests between t7201-t9001. Signed-off-by: Nanako Shiraishi <> Signed-off-by: Junio C Hamano <>
2008-07-23t7601: extend the 'merge picks up the best result' testMiklos Vajna
The test only checked if the best result picking code works if there are multiple strategies set in the config. Add a similar one that tests if the same true if the -s option of git merge was used multiple times. Signed-off-by: Miklos Vajna <> Signed-off-by: Junio C Hamano <>
2008-07-22builtin-merge: give a proper error message for invalid strategies in configMiklos Vajna
'git merge -s foobar' diagnosed invalid "foobar" strategy and errored out with a message, but foobar in pull.twohead or pull.octopus was just silently ignored. This makes invalid strategy both on the command line and in the configuration file to trigger the same error. Signed-off-by: Miklos Vajna <> Signed-off-by: Junio C Hamano <>
2008-07-07Fix on AIXMiklos Vajna
The test failed on AIX (and likely other OS, such as apparently OSX) where wc -l outputs whitespace. Also, avoid unnecessary eval in conflict_count(). Signed-off-by: Miklos Vajna <> Signed-off-by: Junio C Hamano <>
2008-07-01Add new test to ensure git-merge handles pull.twohead and pull.octopusMiklos Vajna
Test if the given strategies are used and test the case when multiple strategies are configured using a space separated list. Also test if the best strategy is picked if none is specified. This is done by adding a simple test case where recursive detects a rename, but resolve does not, and verify that finally merge will pick up the previous. Signed-off-by: Miklos Vajna <> Signed-off-by: Junio C Hamano <>