getReference method
Fetches a reference from a repository for the given ref.
Note: The ref in the URL must be formatted as "heads/branch", not just "branch".
API docs: https://developer.github.com/v3/git/refs/#get-a-reference
Implementation
Future<GitReference> getReference(RepositorySlug slug, String ref) =>
github.getJSON(
'/repos/${slug.fullName}/git/refs/$ref',
convert: GitReference.fromJson,
statusCode: StatusCodes.OK,
);