0

So, lets say I have development branch, and opened a PR for my feature branch into development.

I have a conflict in say, 1 file (or 10, whatever) - bitbucket says what I need to do:

git checkout development
git pull origin feature

...Do merge conflict resolution here...

git commit
git push origin HEAD

Not always I want to do it in command line, especially for major conflicts I prefer IDEA's diff GUI.

I have tried two different ways:

  1. Checkout development, then via menu: VCS->Git->Merge Changes->check the feature branch, check squash commit -> resolve conflicts. The results? a huge local changelog that would create a new direct commit on development with the feature branch contents, instead of just the conflict fix to commit.
  2. Through the branches menu on the bottom right -> choose feature branch -> Merge into current (development), resolving conflicts - and nothing shows on changelist! nothing to commit and push...

As I explained, none reproduce the steps for command line conflict resolution as bit bucket explains.

So how to do this correctly in IDEA?

Carmageddon
  • 2,627
  • 4
  • 36
  • 56

1 Answers1

0

The 2nd way is the correct one. Once conflicts are resolved after the merge then you will have a new commit and you can simply Push to BitBucket. You see nothing in changes since merge produces new commit and no new changes were created since then.

Ruslan Kuleshov
  • 1,934
  • 1
  • 7
  • 11
  • This answer is incorrect, first: I now understand why I didnt see anything to commit - its already committed as a merge, and I just had to load the push screen, and wait long enough to load all the commits In my case, it was 181 commits, when I pushed them, my Bitbucket pull request became marked as MERGED, saying: "XXX remotely merged the pull request from development to release" (in this instance). This means that I bypassed the peer review process of approving a PR and having to click merge button! – Carmageddon Feb 05 '20 at 12:56
  • I reiterate, I would like to resolve the merge conflicts, but not MERGE automatically without having a team member review and approve the merge, and I would like a clean, squash commit on the branch merged to! – Carmageddon Feb 05 '20 at 12:57
  • Regrettably, there is no option for review BitBucket Requests in IntelliJ, there is support for GitHub Pull Requests only. There is a request for BitBucket request, please vote: https://youtrack.jetbrains.com/issue/IDEA-88198 – Ruslan Kuleshov Feb 12 '20 at 11:49