unofficial mirror of emacs-devel@gnu.org 
 help / color / mirror / code / Atom feed
From: dhruva <dhruvakm@gmail.com>
To: "Lynbech Christian" <christian.lynbech@tietoenator.com>
Cc: emacs-devel@gnu.org
Subject: Re: Problem understanding git
Date: Fri, 23 May 2008 17:48:36 +0530	[thread overview]
Message-ID: <e3f230850805230518u2439a6a3v93950a626a7d39ce@mail.gmail.com> (raw)
In-Reply-To: <ytqpwsll6xsy.fsf@ul000205.eu.tieto.com>

Hi,

On Fri, May 23, 2008 at 5:24 PM, Lynbech Christian
<christian.lynbech@tietoenator.com> wrote:
> On one machine, where I have git version 1.5.5.1, I just do a "git pull"
> and the updates comes pouring in, but when I try the same on my laptop
> where I only have git version 1.5.3.4, I get the following (to me)
> cryptic error message:
>
>        You asked me to pull without telling me which branch you
>        want to merge with, and 'branch.master.merge' in
>        your configuration file does not tell me either.  Please
>        name which branch you want to merge on the command line and
>        try again (e.g. 'git pull <repository> <refspec>').
>        See git-pull(1) for details on the refspec.
>

In the .git folder, there is a file 'config'. Ideally, it should have
the following entry:
[branch "master"]
        remote = origin
        merge = refs/heads/master

- Type 'git branch' and you should see a branch named 'master'.
- If you do see, type 'git checkout master' to explicitly switch to
the master branch and do a git pull.
- If you do not see the master branch, type 'git branch -a', you
should see a bunch of 'origin/*' entries of which there will be
'origin/master'.
- If you find 'origin/master', create a local master as 'git branch
--track master origin/master'

I get a feeling that you might have tried to checkout from a non local
branch by doing 'git branch origin/master' or something unknowingly (i
had done it once). Changing to local master by 'git checkout master'
followed by a 'git pull' might work.

-dky

-- 
Contents reflect my personal views only!




  reply	other threads:[~2008-05-23 12:18 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2008-05-23 11:54 Problem understanding git Lynbech Christian
2008-05-23 12:18 ` dhruva [this message]
2008-05-23 13:20   ` Lynbech Christian
2008-05-23 14:00     ` İsmail Dönmez
2008-05-23 15:31       ` dhruva
2008-05-23 17:24         ` Stefan Monnier

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

  List information: https://www.gnu.org/software/emacs/

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

  git send-email \
    --in-reply-to=e3f230850805230518u2439a6a3v93950a626a7d39ce@mail.gmail.com \
    --to=dhruvakm@gmail.com \
    --cc=christian.lynbech@tietoenator.com \
    --cc=emacs-devel@gnu.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.
Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/emacs.git

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 read-only IMAP folder(s) and NNTP newsgroup(s).