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 8129987
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 6, 20262026-06-06T08:31:21+00:00 2026-06-06T08:31:21+00:00

I am new to github. I have been working on a code that I

  • 0

I am new to github. I have been working on a code that I fetched from github. Now I completed making my modifications and I want to push my code to github. I would like to create a fork of the original code that I worked on and push my developed code over that fork. However while I was working on development there has been some changes at the original code. So when I try to push my new code to the fork I get the following error:

git push original master 
To https://github.com/<username>/<projectName>.git
 ! [rejected]        master -> master (non-fast-forward)
error: failed to push some refs to 'https://github.com/<username>/<projectName>.git'
To prevent you from losing history, non-fast-forward updates were rejected
Merge the remote changes (e.g. 'git pull') before pushing again.  See the
'Note about fast-forwards' section of 'git push --help' for details.

Then I used

git pull

which outputted the following:

Pull is not possible because you have unmerged files.
Please, fix them up in the work tree, and then use 'git add/rm <file>'
as appropriate to mark resolution, or use 'git commit -a'.

I can’t continue from this point on. What should I do to commit my project?

  • 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-06T08:31:23+00:00Added an answer on June 6, 2026 at 8:31 am

    Well, git is telling you what to do. If you want to pull, you need to finish the incomplete merge first. Git status should tell you what files are as yet unmerged. You need to resolve the merge conflicts and then use git add on the file(s) to tell git that the conflict is resolved.

    With that said, if your goal is to work off a fork, you should fork the code first, clone the forked code, make your modifications to it, and then push your changes back to the fork. Once that’s done, you can submit a pull request to the authors of the original project to integrate your changes.

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

Sidebar

Related Questions

I have a problem in running a new project which I downloaded from github.
I have been using git to push my local code to a server. I
I have a project that I've been working on called system that I set
I have not been working with Monotouch (or the iphone for that matter) for
I am relatively new to rails and have been working my way through the
I have a repo on GitHub with a single branch master that I've been
I'm pretty new to web development. Lately I have been making a site using
I use tag-it plugin from https://github.com/aehlke/tag-it/downloads . How to disable adding new tags? $(document).ready(function
Howdy. I've been tasked with making a Facebook game, but I'm new to Facebook
I have a repository on Github that is a fork of another repository. I

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.