Re: Git repo on a machine with zero commits is ahead of remote by 103 commits.. !

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



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
--
To unsubscribe from this list: send the line "unsubscribe git" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[Index of Archives]     [Linux Kernel Development]     [Gcc Help]     [IETF Annouce]     [DCCP]     [Netdev]     [Networking]     [Security]     [V4L]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux SCSI]     [Fedora Users]