git.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Han-Wen Nienhuys <hanwen@xs4all.nl>
To: git@vger.kernel.org
Cc: git@vger.kernel.org
Subject: Re: Pulling from refs/remotes/ ?
Date: Thu, 24 May 2007 22:35:17 -0300	[thread overview]
Message-ID: <46563D55.3070607@xs4all.nl> (raw)
In-Reply-To: <7v7iqxvgx8.fsf@assigned-by-dhcp.cox.net>

Junio C Hamano escreveu:
> Han-Wen Nienhuys <hanwen@xs4all.nl> writes:
> 
>> why can't I pull from a remote?  I can do 
>>
>>   git log REMOTE-BRANCH
>>   git diff BRANCH REMOTE-BRANCH
>>
>> etc. But pulling yields
>>
>>  [hanwen@haring foobar]$ git pull . origin/nonrandr-setup
>>  error: no such remote ref refs/heads/origin/nonrandr-setup
>>  Fetch failure: .
>>
>> also, "Fetch failure: .", what is that supposed to mean?
> 
> You are treating your local repository as if it is a remote
> repository somewhere else, namely, '.' (current repository).
> 
> Notice "git log" and "git diff" are LOCAL operations?  "git
> pull" is "git fetch" which is a remote operation (i.e. it
> interacts with a remote repository) followed by "git merge"
> which is a local operation to merge in what was fetched or what
> you already have locally.
> 
> I think you would want:
> 
> 	git merge REMOTE-BRANCH
> 
> e.g. "git merge origin/nonrandr-setup".

Yes, that works, thanks. Wouldn't it be more consistent with this
reasoning to disallow 

  git pull . LOCAL-BRANCH 

too?

I still think that "fetch failure" is a bad error message. 
What information does it convey?


-- 
 Han-Wen Nienhuys - hanwen@xs4all.nl - http://www.xs4all.nl/~hanwen

  reply	other threads:[~2007-05-25  1:37 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2007-05-25  1:12 Pulling from refs/remotes/ ? Han-Wen Nienhuys
2007-05-25  1:19 ` Junio C Hamano
2007-05-25  1:35   ` Han-Wen Nienhuys [this message]
2007-05-25  1:53     ` Junio C Hamano
2007-05-25  2:24       ` Han-Wen Nienhuys
2007-05-25  3:06         ` Junio C Hamano
2007-05-26 19:47           ` Han-Wen Nienhuys

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=46563D55.3070607@xs4all.nl \
    --to=hanwen@xs4all.nl \
    --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).