1

I've got strange issue today. So I have forked repository on my github account. I cloned it and introduced some changes. When I pushed it, everything was fine, but respective subpage on github is silent about my change. Now when I take pull or push on that local branch it says everything is up-to-date.

git checkout mychange Switched to branch 'mychange' Your branch is up-to-date with 'origin/mychange'. 

I've checked whether I work on detached HEAD, but everything is fine.

What's more, I cloned that repo in a different folder, then printed the logs and my commit indeed is there! So why I can't see it on github?

1
  • Yes, I am sure. Commented Feb 17, 2017 at 12:50

2 Answers 2

3

Make sure you select your mychange branch. Default is master branch.

enter image description here


Go to https://github.com/USER-NAME/REPO-NAME/tree/mychange

Replace USER_NAME, REPO-NAME with exact value. In URL mychange is your branch name.

Edit:

You mentioned in comment that you have no difference with git diff origin/mychange, so seems like your push was successful.

Check the commit lists of origin/mychange by git log origin/mychange and see if your last commit exist or not!

Sign up to request clarification or add additional context in comments.

6 Comments

I'm checking mychange branch on github. Nothing there.
git fetch. What is the output of get diff origin/mychange?
being on local branch mychange command git diff origin/mychange gives empty line
Ok. Seems your changes are pushed as no changes are found. What is the output of git log origin/mychange? Do you see your last commit here ?
If your repo is public then Can you attach your Repo link in OP?
|
1

1. If you really dont have any errors, that seems like you are pushing in wrong repository. Run git remote -v and ensure that origin is that repository you are checking on github.

2. And to ensure that you actually pushed your changes in the remote repo run:

git diff mychange origin/mychange git fetch origin git diff mychange origin/mychange 

Diff should prints nothing both times.

3. If all of this seems alright, then be sure, that you checked the branch by a filter on the commits tab (https://github.com/USER-NAME/REPO-NAME/commits/BRANCH-NAME), because you could just dont noticed it, like this: Commits page with filled branch filter field

4. If you still see different commits in the remote repo throught git bash and on the site, then try to change remote head of the branch somehow. For example you can amend your last commit and then do forced push.

I think, that there (on GitHub) are some hooks to update web representation. And they didn't worked for some reason in your last push to this branch. So another push will run it.

In that particular case, that was a solution.

9 Comments

I doublechecked that as you suggested but it's okay. Remember that I cloned the repository to a directly from github to another folder, where I could see my commit in logs but not on website.
I've checked the output of your commands as well. The same commit everywhere.
Is your repo public? Can you give us a repo link and your commit hash?
And the branch name too
Can you joint to freenode irc? webchat.freenode.net write to Ovsyanka plz.
|

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.