Skip to content

Conversation

@harrisoncramer
Copy link
Owner

This MR updates the function that checks the stability of the branch and MR.

There is now one function responsible for checking whether the current branch is ahead/behind it's tracking branch. That function will warn the user if that's the case for all three possibilites (ahead, behind, or ahead and behind).

The second function is responsible for alerting the user if the status of the current MR is bad: merged, closed, or with conflicts.

These should address the points outlined in the issue outlined by Jakub. For instance, in the complex case where the user is setup to track a remote and they are behind the remote, and the MR associated with that remote has already been closed, they will get both warnings, which is accurate.

Plesae @jakubbortlik give this a look when you have time. Thanks.

@harrisoncramer harrisoncramer marked this pull request as ready for review October 11, 2024 17:11
Copy link
Collaborator

@jakubbortlik jakubbortlik left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hi Harrison, this looks much more robust than the original way of checking for branch state. I have three small suggestions that you may consider. I've tested the basic cases and all worked as expected. Thanks!

harrisoncramer and others added 4 commits October 12, 2024 10:00
Co-authored-by: Jakub F. Bortlík <jakub.bortlik@proton.me>
Co-authored-by: Jakub F. Bortlík <jakub.bortlik@proton.me>
Co-authored-by: Jakub F. Bortlík <jakub.bortlik@proton.me>
@harrisoncramer harrisoncramer merged commit 96efdc2 into develop Oct 12, 2024
6 checks passed
harrisoncramer added a commit that referenced this pull request Oct 13, 2024
fix: Error messages and run all tests (#381)
feat: Automatically open fold under cursor (#380)
fix: Discussion ID is not required (#383)
chore: Add more emojis (#384)
fix: Publish all drafts (#391)
fix: Make discussion tree buffers no-modifiable (#394)
fix: Incorrect warning about commits (#395)
fix: Show draft replies in the correct tree (#396)
fix: Cannot choose merge requests (#398)

---------

Co-authored-by: George Kontridze <george.kontridze@gmail.com>
Co-authored-by: Jakub F. Bortlík <jakub.bortlik@proton.me>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants