gitload

Crates.iogitload
lib.rsgitload
version0.1.3
created_at2025-01-03 14:54:25.323433+00
updated_at2025-01-06 11:22:15.149543+00
descriptiondownload any single file or dir from github
homepage
repository
max_upload_size
id1502487
size45,932
levinion (levinion)

documentation

README

gitload

Gitload is a Rust library for downloading specific folders from GitHub repositories.

usage

use anyhow::Result;
use gitload::DownloaderBuilder;

#[tokio::main]
async fn main() -> Result<()> {
    let downloader = DownloaderBuilder::new("<user>", "<repo>", "<directory>")
        .on_process(|process| {
            println!(
                "process: {}/{}\t{:.0}%",
                process.current,
                process.all,
                process.percent() * 100.
            );
        })
        .build();
    downloader.download().await
}
Commit count: 0

cargo fmt