git.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Matthieu Moy <Matthieu.Moy@grenoble-inp.fr>
To: shawn wilson <ag4ve.us@gmail.com>
Cc: Git List <git@vger.kernel.org>
Subject: Re: push fail
Date: Mon, 17 Mar 2014 14:36:04 +0100	[thread overview]
Message-ID: <vpq38ih7xrv.fsf@anie.imag.fr> (raw)
In-Reply-To: <CAH_OBie+KrSjtqLinbv8sJAOCu26j8xVzBQJHdHTB44V07GsXg@mail.gmail.com> (shawn wilson's message of "Mon, 17 Mar 2014 09:06:56 -0400")

shawn wilson <ag4ve.us@gmail.com> writes:

> How do I get more info here (and hopefully resolve this)?
>
>  % git push
> To ssh://server/foo/repo.git
>  ! [rejected]        test -> test (non-fast-forward)
> error: failed to push some refs to 'ssh://server/foo/repo.git'

You probably have a configuration that disables advices (look in
~/.gitconfig for an [advice] section. If you're a beginner, you probably
shouldn't deactivate these advices).

Git normally says something like this:

To /tmp/git
 ! [rejected]        branch3 -> branch3 (non-fast-forward)
error: failed to push some refs to '/tmp/git'
hint: Updates were rejected because the tip of your current branch is behind
hint: its remote counterpart. Merge the remote changes (e.g. 'git pull')
hint: before pushing again.
hint: See the 'Note about fast-forwards' in 'git push --help' for details.

The latest version says this which you may find clearer:

To /tmp/git
 ! [rejected]        branch3 -> branch3 (fetch first)
error: failed to push some refs to '/tmp/git'
hint: Updates were rejected because the remote contains work that you do
hint: not have locally. This is usually caused by another repository pushing
hint: to the same ref. You may want to first integrate the remote changes
hint: (e.g., 'git pull ...') before pushing again.
hint: See the 'Note about fast-forwards' in 'git push --help' for details.

-- 
Matthieu Moy
http://www-verimag.imag.fr/~moy/

      parent reply	other threads:[~2014-03-17 13:36 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-03-17 13:06 push fail shawn wilson
2014-03-17 13:34 ` Dragos Foianu
2014-03-18  1:58   ` shawn wilson
2014-03-17 13:36 ` Matthieu Moy [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=vpq38ih7xrv.fsf@anie.imag.fr \
    --to=matthieu.moy@grenoble-inp.fr \
    --cc=ag4ve.us@gmail.com \
    --cc=git@vger.kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).