I have 2 non-bare repositories and one bare repositories set up.

After the first repository commits to itself and then pushes to the bare repository till here everyhing is normal.

Then in the second repository I clone the bare repo and I get the contents into the second repo.

Then in the second repo I add a new file and commit to itself still I have not pused into bare repo.

Then I do a git status and I get the message like "Your branch is ahead of origin/master by 1 commit" : So this is natural behaviour since I have not pushed into bare repo yet.

And later i push into the bare repo and cd to the bare repo and do a **git log** and I see the latest commit is successful.

Then I return back to the second repo and do a **git status** and still I'm getting the message "Your branch is ahead of origin/master by 1 commit".

Why am I still getting the same message even after the bare repo has the latest commit.

```
**EDIT**:And if I try to pull or fetch the message still remains.
1) user@ubuntu:~/user2$ git pull /home/user/central [/home/user/central-Bare repo]

2) user@ubuntu:~/user2$ git fetch /home/user/central
From /home/user/central
 * branch            HEAD       -> FETCH_HEAD [And this fetch command has no output why does this happen.Am I fetching correctly]

```

And when i do a diff b/w the master and the origin/master I get the foll:

```
user@ubuntu:~/user2$ git diff master origin/master
diff --git a/anotherfile.txt b/anotherfile.txt
deleted file mode 100644
index 6acd600..0000000
--- a/anotherfile.txt
+++ /dev/null
@@ -1,2 +0,0 @@
-This is a second file to be committed
-hello

```

I have added a few files to user2 repo and the git log for user2 which is a non-bare repo and the git log for the bare repo is the same .
The git status for user2 repo is as shown:

```
user@ubuntu:~/user2$ git status
# On branch master
# Your branch is ahead of 'origin/master' by 4 commits.
#
nothing to commit (working directory clean)

```

And the result of git branch -vva result in the non-bare repo user2 is as shown:

```
user@ubuntu:~/user2$ git branch -vva
* master                dac4ae0 [origin/master: ahead 4] Fifth Commit
  remotes/origin/HEAD   -> origin/master
  remotes/origin/master 8cfb52f Initial Commit

```