Reputation: 13925
If I compare the output of git log
and the commit history in the Xcode 9 Source Control Navigator, there is a marked difference and many recent commits tend to be missing. For instance, right now git log
lists 10 commits from today, whereas only 5 are visible in Xcode. I think Xcode's commit history does update occasionaly, but I haven't noticed any patterns in its behavior. In any case, I do not recall this being a problem up until Xcode 9 and the changes it includes to how source control is handled.
I've tried switching to another branch and then back to master. The Pull and Fetch and Refresh Status items in the Source Control menu have no effect. In Preferences/Source Control, Refresh Local Status Automatically is enabled. Restarting Xcode also does not help.
Admittedly, I do tend to do most of my interaction with git (pull, commit, push etc.) from a separate terminal window. Xcode is of course much easier to use for diffing.
Here are two screenshots that illustrate the issue (5 vs 15 commits):
This image shows the output of git log --oneline --decorate --graph --all
.
Does anyone know what might be causing this issue?
Upvotes: 1
Views: 1384
Reputation: 38136
Commits are not missing to show in xcode.
The different results caused by xcode only show the commits on master
branch, while git log
show the commits for all branches.
You can obviously find in the output of git log --oneline --decorate --graph --all
that the commits ce514
, 12b6a
, ef7a0
, ccdfc
etc on master
branch, while the commits from 8487c
to f5da3
on other branches (not master
branch).
And if you execute the command git log master --oneline
, it will list the commits only on master
branch, and the result will be same as xcode shows.
Upvotes: 4