Skip to content

Merge Sha #366

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

Open
BenLiyanage opened this issue Jun 26, 2023 · 1 comment
Open

Merge Sha #366

BenLiyanage opened this issue Jun 26, 2023 · 1 comment

Comments

@BenLiyanage
Copy link

This graphQL query gets the merge commit sha, which is what github uses internally on PRs. Would be nice if this was available to keep things consistent.

{
  viewer {
    login
  }
  repository(name: "dbt", owner: "vidahealth") {
    pullRequest(number: 1843) {
      potentialMergeCommit {
        oid
      }
    }
  }
}

This sha is useful for file diffs with out having to retrieving an extended git commit history.

@BenLiyanage
Copy link
Author

I didn't exactly know how to build a github action so I did not get this working on my end.

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

No branches or pull requests

1 participant