Skip to content
This repository has been archived by the owner on Nov 22, 2022. It is now read-only.

fix mr merge failing on detached branch #743

Merged
merged 1 commit into from
May 27, 2021
Merged

Conversation

profclems
Copy link
Owner

@profclems profclems commented May 27, 2021

mr merge fails with error could not determine current branch: git: not on any branch when run on a detached branch.

This is due to glab fetching the current branch first before checking if a merge request ID was provided as argument.

Resolves #735

`mr merge` fails with error `could not determine current branch: git: not on any branch` when run on a detached branch.

This is due to glab fetching the current branch first before checking if a merge request ID was provided as argument.
@codecov
Copy link

codecov bot commented May 27, 2021

Codecov Report

Merging #743 (2900bc4) into trunk (cd37ff9) will increase coverage by 0.01%.
The diff coverage is 100.00%.

Impacted file tree graph

@@            Coverage Diff             @@
##            trunk     #743      +/-   ##
==========================================
+ Coverage   58.60%   58.61%   +0.01%     
==========================================
  Files          93       93              
  Lines        6663     6665       +2     
==========================================
+ Hits         3905     3907       +2     
  Misses       2379     2379              
  Partials      379      379              
Impacted Files Coverage Δ
commands/mr/mrutils/mrutils.go 66.45% <100.00%> (+0.43%) ⬆️

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update cd37ff9...2900bc4. Read the comment docs.

@profclems profclems merged commit be2dec0 into trunk May 27, 2021
@profclems profclems deleted the fix-merge-detached-branch branch May 27, 2021 18:08
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Can't merge a Merge Request if I am in detached HEAD state
1 participant