From fc6c4e96f13fe595fc8991d91c56f2abbe67dc89 Mon Sep 17 00:00:00 2001 From: John Keeping Date: Sun, 7 Jul 2013 20:02:14 +0100 Subject: push: avoid suggesting "merging" remote changes With some workflows, it is more suitable to rebase on top of remote changes when a push does not fast-forward. Change the advice messages in git-push to suggest that a user "integrate the remote changes" instead of "merge the remote changes" to make this slightly clearer. Also change the suggested 'git pull' to 'git pull ...' to hint to users that they may want to add other parameters. Suggested-by: Philip Oakley Signed-off-by: John Keeping Signed-off-by: Junio C Hamano diff --git a/builtin/push.c b/builtin/push.c index 909c34d..878dd9d 100644 --- a/builtin/push.c +++ b/builtin/push.c @@ -204,8 +204,8 @@ static void setup_default_push_refspecs(struct remote *remote) static const char message_advice_pull_before_push[] = N_("Updates were rejected because the tip of your current branch is behind\n" - "its remote counterpart. Merge the remote changes (e.g. 'git pull')\n" - "before pushing again.\n" + "its remote counterpart. Integrate the remote changes (e.g.\n" + "'git pull ...') before pushing again.\n" "See the 'Note about fast-forwards' in 'git push --help' for details."); static const char message_advice_use_upstream[] = @@ -216,15 +216,15 @@ static const char message_advice_use_upstream[] = static const char message_advice_checkout_pull_push[] = N_("Updates were rejected because a pushed branch tip is behind its remote\n" - "counterpart. Check out this branch and merge the remote changes\n" - "(e.g. 'git pull') before pushing again.\n" + "counterpart. Check out this branch and integrate the remote changes\n" + "(e.g. 'git pull ...') before pushing again.\n" "See the 'Note about fast-forwards' in 'git push --help' for details."); static const char message_advice_ref_fetch_first[] = N_("Updates were rejected because the remote contains work that you do\n" "not have locally. This is usually caused by another repository pushing\n" - "to the same ref. You may want to first merge the remote changes (e.g.,\n" - "'git pull') before pushing again.\n" + "to the same ref. You may want to first integrate the remote changes\n" + "(e.g., 'git pull ...') before pushing again.\n" "See the 'Note about fast-forwards' in 'git push --help' for details."); static const char message_advice_ref_already_exists[] = -- cgit v0.10.2-6-g49f6 From 153d7265ef1277c1c9971780ad035a530e305f78 Mon Sep 17 00:00:00 2001 From: John Keeping Date: Sun, 7 Jul 2013 20:02:15 +0100 Subject: pull: change the description to "integrate" changes Since git-pull learned the --rebase option it has not just been about merging changes from a remote repository (where "merge" is in the sense of "git merge"). Change the description to use "integrate" instead of "merge" in order to reflect this. Signed-off-by: John Keeping Signed-off-by: Junio C Hamano diff --git a/Documentation/git-pull.txt b/Documentation/git-pull.txt index 24ab07a..6ef8d59 100644 --- a/Documentation/git-pull.txt +++ b/Documentation/git-pull.txt @@ -3,7 +3,7 @@ git-pull(1) NAME ---- -git-pull - Fetch from and merge with another repository or a local branch +git-pull - Fetch from and integrate with another repository or a local branch SYNOPSIS diff --git a/git-pull.sh b/git-pull.sh index 638aabb..58597db 100755 --- a/git-pull.sh +++ b/git-pull.sh @@ -5,7 +5,7 @@ # Fetch one or more remote refs and merge it/them into the current HEAD. USAGE='[-n | --no-stat] [--[no-]commit] [--[no-]squash] [--[no-]ff] [-s strategy]... [] ...' -LONG_USAGE='Fetch one or more remote refs and merge it/them into the current HEAD.' +LONG_USAGE='Fetch one or more remote refs and integrate it/them with the current HEAD.' SUBDIRECTORY_OK=Yes OPTIONS_SPEC= . git-sh-setup -- cgit v0.10.2-6-g49f6