Asthowen / github-updater-rust

A small library to update rust binaries from GitHub releases.

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

github-updater

A small library to update rust binaries from GitHub releases.

Basic usage

Create builder

let mut updater_builder = GithubUpdater::builder()
    .with_initialized_reqwest_client()
    .with_download_path(&"~/downloads")
    .with_repository_infos("repository-owner", "repository-name")
    .with_app_name("app-name")
    .with_rust_target("i686-unknown-linux-musl")
    .with_release_file_name_pattern("{app_name}-{app_version}-{rust_target}")
    .with_file_extension("exe")
    .with_github_token("")
    .build()
    .unwrap();

Download update if needed

updater_builder.update_if_needed().await?;

Force update

updater_builder.force_update().await?;

Contributors

Asthowen

License

github-updater-rust | GNU General Public License v3.0

About

A small library to update rust binaries from GitHub releases.

License:GNU General Public License v3.0


Languages

Language:Rust 100.0%