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

  • Home
  • SEARCH
  • 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 6964675
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 27, 20262026-05-27T15:57:17+00:00 2026-05-27T15:57:17+00:00

I’m following the the workflow described here , as I found many references pointing

  • 0

I’m following the the workflow described here, as I found many references pointing to this page as a good workflow. As mentioned in the article, “feature” branches are shared between developers, but do not go to the central repository.

Let’s say a developer “A” starts a new feature branch with git checkout -b newfeature develop. Now let’s say that developer “B” needs also to work on this feature. This is my problem.

What I did:

  1. developer “B” adds developer A’s machine as a remote
  2. developer “B” runs git branch remoteA/newfeature
  3. developer “B” works on this branch, commit his work and pushes the changes back to remoteA.

Step 3 is not working, right now. I get a message:

remote: error: By default, updating the current branch in a non-bare
repository is denied, because it will make the index and work tree
inconsistent with what you pushed, and will require ‘git reset –hard’
to match the work tree to HEAD.

remote: error: You can set ‘receive.denyCurrentBranch’ configuration
variable to ‘ignore’ or ‘warn’ in the remote repository to allow
pushing into its current branch; however, this is not recommended
unless you arranged to update its work tree to match what you pushed
in some other way.

remote: error: To squelch this message and still keep the default
behaviour, set receive.denyCurrentBranch’ configuration variable to
‘refuse’.

I have already set sharedRepository = true, but it did not help.

I have 2 questions:

  1. what’s the correct way to share feature branches between developers?
  2. how can I push back the changes in developer B’s repository to developer A’s original one?
  • 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-05-27T15:57:17+00:00Added an answer on May 27, 2026 at 3:57 pm

    You can push to a non-bare repo. What you cannot do is push to a non-bare repo that has the branch that you are pushing to checked out. The reason for this should make sense. Changing the files that someone else is possibly working on would be incorrect.

    Typically you will want to push to master or some other common shared branch. In order to avoid this conflict, the owner of the remote non-bare repo should work on a local branch or at least some other branch. Then you can push to the shared branch.

    To use your example:

    1. developer “B” adds developer A’s machine as a remote
    2. developer “B” runs git branch remoteA/newfeature
      1. developer “A” does work on a local branch. git checkout -b work-newfeature
    3. developer “B” works on this branch, commit his work and pushes the changes back to remoteA.
      1. Developer “A” rebases to get the new work: git rebase newfeature
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I'm parsing an RSS feed that has an ’ in it. SimpleXML turns this
I have a string like this: La Torre Eiffel paragonata all’Everest What PHP function
Basically, what I'm trying to create is a page of div tags, each has
link Im having trouble converting the html entites into html characters, (&# 8217;) i
That's pretty much it. I'm using Nokogiri to scrape a web page what has
I want to count how many characters a certain string has in PHP, but
For some reason, after submitting a string like this Jack’s Spindle from a text
this is what i have right now Drawing an RSS feed into the php,
I'm using v2.0 of ClassTextile.php, with the following call: $testimonial_text = $textile->TextileRestricted($_POST['testimonial']); ... and
I have this code: - (void)parser:(NSXMLParser *)parser foundCDATA:(NSData *)CDATABlock { NSString *someString = [[NSString

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.