Last active
October 24, 2022 12:31
-
-
Save Hollywood/75a0569285e673280422e552631e29fd to your computer and use it in GitHub Desktop.
GraphQL Branch and Commit Queries by Repository
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
query getCommitsByBranchByRepo($org:String!,$repo:String!) { | |
organization(login:$org) { | |
name | |
repository(name:$repo) { | |
name | |
refs(refPrefix: "refs/heads/", first: 10) { | |
nodes { | |
id | |
name | |
target { | |
... on Commit { | |
history(first: 100) { | |
nodes { | |
messageHeadline | |
committedDate | |
author { | |
name | |
} | |
} | |
pageInfo { | |
hasNextPage | |
endCursor | |
} | |
} | |
} | |
} | |
} | |
pageInfo { | |
hasNextPage | |
endCursor | |
} | |
} | |
} | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment