git.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Johannes Sixt <j.sixt@viscovery.net>
To: Srirang Doddihal <om.brahmana@gmail.com>
Cc: git@vger.kernel.org
Subject: Re: Git repo on a machine with zero commits is ahead of remote by 103 commits.. !
Date: Tue, 25 Jan 2011 08:22:10 +0100	[thread overview]
Message-ID: <4D3E7A22.7090008@viscovery.net> (raw)
In-Reply-To: <AANLkTikj06sjTbNd8afk9cY2=_Hy+kT+J1NCjR-fKP5J@mail.gmail.com>

Am 1/25/2011 6:48, schrieb Srirang Doddihal:
> I am using a simple git based deployment for my rails app and here is
> my setup and current status:
> 
> 1) Git repo initialized on my local development machine with a sample file.
> 2) Pushed to remote repo on Github.com
> 3) Subsequent pushes and pulls made from local development machine
> 4) Repository cloned on the deployed machine
> 5) Subsequent pulls made from the deployed machine (but no commits or
> pushes are made on this machine)
> 
> Now when I run "git status" on the deployed machine it says :
> 
> # On branch master
> # Your branch is ahead of 'origin/master' by 103 commits.
> 
> git pull origin master -- says it is Already up to date

This 'git pull' is very explicit. I.e., you specify the remote and the
branch; in this case, no remote-tracking branches, like origin/master, are
updated.

Since you cloned the repository (I assume without any special options),
you already have a configuration such that you can use this shorter command:

   git pull

to merge origin's master into your local master. As a side-effect, it also
updates origin/master.

-- Hannes

  reply	other threads:[~2011-01-25  7:22 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-01-25  5:48 Git repo on a machine with zero commits is ahead of remote by 103 commits.. ! Srirang Doddihal
2011-01-25  7:22 ` Johannes Sixt [this message]
2011-01-25  7:23 ` Jay Soffian
2011-01-25 23:09   ` Srirang Doddihal

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=4D3E7A22.7090008@viscovery.net \
    --to=j.sixt@viscovery.net \
    --cc=git@vger.kernel.org \
    --cc=om.brahmana@gmail.com \
    /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).