pub struct GitHubClient { /* private fields */ }Expand description
GitHub API client for fetching release information and downloading assets.
Implementations§
Source§impl GitHubClient
impl GitHubClient
Sourcepub fn new() -> Self
pub fn new() -> Self
Create a new client, reading auth token from KISH_GITHUB_TOKEN or GITHUB_TOKEN.
Sourcepub fn find_asset_url(
&self,
owner: &str,
repo: &str,
version: &str,
asset_name: &str,
) -> Result<String, String>
pub fn find_asset_url( &self, owner: &str, repo: &str, version: &str, asset_name: &str, ) -> Result<String, String>
Look up a GitHub release by tag, trying v{version} first then {version}.
Returns the download URL of the named asset.
Trait Implementations§
Auto Trait Implementations§
impl Freeze for GitHubClient
impl RefUnwindSafe for GitHubClient
impl Send for GitHubClient
impl Sync for GitHubClient
impl Unpin for GitHubClient
impl UnsafeUnpin for GitHubClient
impl UnwindSafe for GitHubClient
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more