2013-02-23 118 views
1

我在使用git status时遇到问题。我得到这个输出:执行git状态时面临问题

# On branch master 
# Your branch is ahead of 'origin/master' by 1 commit. 
# 
nothing to commit, working directory clean 

首先,提交和推送自述文件(README.md)完美地工作。我该如何解决这个问题?

+0

什么问题? – oseiskar 2013-02-23 11:07:54

+0

瓦特母鸡我运行git状态命令,我得到上面的输出... – h4kl0rd 2013-02-23 11:29:38

回答

2

您可以通过推动它再次掌握解决它:

git push 
or, if your master branch wasn't tracking origin/master already 
git push -u origin master 

(请参见有关“跟踪”业务“What's the difference between git config and git push --set-upstream”和“hat exactly does the “u” do? “git push -u origin master” vs “git push origin master

的唯一一次混帐推不解决这种情况是当你需要做一个git以更新本地回购在商店起源SHA1取。
请参阅“git: Your branch is Ahead by X commits”。

+0

我试着git推-u起源主,但给出了同样的错误 – h4kl0rd 2013-02-23 12:49:35

+0

@ user1984266和'git fetch origin',后面跟着'git status'? – VonC 2013-02-23 12:54:23