Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: [MER-1493] show up to date info about branches in stack tree #96

Merged
merged 13 commits into from
May 8, 2023

Conversation

doratzeng
Copy link
Contributor

@doratzeng doratzeng commented Apr 28, 2023

add the following info about each branch for av stack tree (will probably need some UI improvements)

  • is it up to date with parent branch
  • is it up to date with upstream/remote branch
  • if PR link if it exists

Screen Shot 2023-05-01 at 2 12 32 PM

@aviator-app
Copy link
Contributor

aviator-app bot commented Apr 28, 2023

Current Aviator status

Aviator will automatically update this comment as the status of the PR changes.
Comment /aviator refresh to force Aviator to re-examine your PR (or learn about other /aviator commands).

This PR was merged using Aviator.

// Check if branch is up to date with the upstream branch.
// This is doing `git diff <givenBranch> remotes/origin/<givenBranch>`
func getUpstreamStatus(repo *git.Repo, branch meta.Branch) (string, error) {
upstreamExists, err := repo.DoesRemoteBranchExist(branch.Name)
Copy link
Contributor Author

Choose a reason for hiding this comment

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

note that this only checks the local reference for if the upstream branch exists. also if the branch has already been merged and deleted, we will not display the not pushed messaged.

discussed offline with @draftcode , I think this should be ok for now.

@doratzeng doratzeng requested a review from draftcode May 2, 2023 22:02
@aviator-app aviator-app bot merged commit e3a26cd into master May 8, 2023
@aviator-app aviator-app bot deleted the dt-branch-status branch May 8, 2023 19:10
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants