Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 7832797
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 2, 20262026-06-02T12:25:01+00:00 2026-06-02T12:25:01+00:00

I have a folder running locally that contains a website. It runs on xampp

  • 0

I have a folder running locally that contains a website. It runs on xampp on my computer quite happily. I know that has been hooked up to git in the past and I continue to add, commit and push my changes through the command line and it all works as all my other git repos do, except they update on my github dashboard online to show when they were last edited etc.

Problem is this one folder, Demo, isn’t updating the supposedly connected repo on my github dashboard.. I’ve made loads of changes and I’m committing it to somehwere but it’s not where I expected… its showing the most recent changes being over 4 months ago! Is there any way to easily reconnect the two? I dont’ mind losing whatevers in the ghost repo showing on github but I can’t lose anything on my local Demo folder. I’m happy enough on git to do the basics but if anything unexpected happens I get terrified I’m going to delete everything!

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-02T12:25:02+00:00Added an answer on June 2, 2026 at 12:25 pm

    That message means that your local repo has diverged from the GitHub remote repo; that is, there are local commits that don’t exist remotely, and vice versa.

    If you really don’t care what’s happened to the remote repo, then you can run git push -f to force the push through, but if there are any other repos (yours or anyone else’s) that have already pulled the non-local changes that have somehow ended up on GitHub, then this will really screw things up for them! Any changes on GitHub that you don’t have locally will be lost.

    If in doubt, commit any local changes, make a note of the current HEAD commit ID (you can use git show to find it) and then pull down the remote changes, fix any merge conflicts, and push back up. If things go wrong, you can always just git reset --hard <commit-id> to go back to where you were before. This route doesn’t modify history, so there’s no danger of losing anything.

    Basically you need to be careful in Git with any operation that modifies the commit history of a repo, which push -f does, since it’ll potentially lead to inconsistent histories between repos. On the other hand, if you only append to a repo’s history (which is what you should be doing, e.g. with git commit, git pull, git merge, etc.) then if it breaks, you can always get it back into a working state just by rewinding to before the offending commits with git reset.


    Also, you can see the commits on GitHub that you don’t have with git log origin/master...master, or git diff origin/master...master to see the actual changes (make sure you run git fetch first).

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I am running a website locally. I have one main folder, which contains all
I'm running a Google App locally. I have a folder with static images I
I have an MVC 3 application that works fine when running locally from visual
I have a folder which contains few files and some directories which I need
I have a fresh git-svn repo (11.13 GB) that has over a 100,000 objects
I have a folder with Tomcat7 installed on my disk that I use to
I have a folder in my C: drive as C:\app_config\java_app This folder contains some
I have developed the SSRS reports. It is running fine locally. but after deployed
We have found a problem with our deployment to a production server that runs
In my environment, I have several projects that involve running NTFS ACL audit reports

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.