Skip to main content

ReleaseClient

Trait ReleaseClient 

Source
pub trait ReleaseClient: Send {
    // Required methods
    fn list(
        &self,
        owner: &str,
        repo: &str,
        limit: usize,
    ) -> Result<Vec<Release>>;
    fn get(&self, owner: &str, repo: &str, tag: &str) -> Result<Release>;
    fn edit(
        &self,
        owner: &str,
        repo: &str,
        tag: &str,
        name: Option<&str>,
        description: Option<&str>,
    ) -> Result<()>;
    fn delete(&self, owner: &str, repo: &str, tag: &str) -> Result<()>;
}

Required Methods§

Source

fn list(&self, owner: &str, repo: &str, limit: usize) -> Result<Vec<Release>>

Source

fn get(&self, owner: &str, repo: &str, tag: &str) -> Result<Release>

Source

fn edit( &self, owner: &str, repo: &str, tag: &str, name: Option<&str>, description: Option<&str>, ) -> Result<()>

Update release metadata. name / description are both optional — pass None to leave them unchanged.

Source

fn delete(&self, owner: &str, repo: &str, tag: &str) -> Result<()>

Delete the release. On GitLab this only removes the release entity (the underlying tag stays); on GitHub the release deletion API likewise leaves the tag intact (use torii tag delete separately if you want both gone).

Dyn Compatibility§

This trait is dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety".

Implementors§