grab-github
A library to interact with GitHub's Get Tree and Get Blob APIs for the purposes of downloading a repository without git.
Downloading functionality is only suitable for small repositories at the moment as it quickly runs up against GitHub's secondary rate limits.
Example Usage
use ;
use Path;
// Specify the user, repository name, and branch (or commit hash)
let repo = new;
// Obtain the directory listing of githubtraining/hellogitworld
let tree = get.await?;
// Find a file in the directory tree with the given path.
let file = tree.resolve_blob.unwrap;
// GitHub personal access token will be filled from environment
// variable `GITHUB_ACCESS_TOKEN` if set.
let config = new;
// Download this file into the output directory.
download_tree.await?;
// ...or you can do
download_tree.await?;
// ...or just
download.await?;