Add diffs type to commit on graphql
What does this MR do and why?
Adds an endpoint under commits
on GraphQL.
This mr is intended to allow us to query the diff of a specific commit or list of commits of a mr.
Fixes: https://gitlab.com/gitlab-com/account-management/eastern-north-america/red-hat/red-hat-kernel-team/-/issues/116
Fixes: #366639
Screenshots or screen recordings
How to set up and validate locally
Example query:
query MyQuery($namespace: ID!, $iid: String!) {
project(fullPath: $namespace) {
mergeRequest(iid: $iid) {
commits {
nodes {
diffs {
bMode
aMode
oldPath
newPath
newFile
diff
deletedFile
}
}
}
}
}
}
{
"namespace": "jashkenas/Underscore",
"iid": "1"
}
MR acceptance checklist
This checklist encourages us to confirm any changes have been analyzed to reduce risks in quality, performance, reliability, security, and maintainability.
-
I have evaluated the MR acceptance checklist for this MR.
Edited by Lucas Zampieri