Skip to main content

create_commit

Function create_commit 

Source
pub async fn create_commit(
    configuration: &Configuration,
    org: &str,
    repo: &str,
    branch: &str,
    message: &str,
    author: &CommitAuthor,
    files: &[CommitFile],
    base_sha: Option<&str>,
) -> Result<CommitResponse, Error<CreateCommitError>>
Expand description

Programmatically create a commit with file operations.

This wraps the generated post_by_org_by_repo_commits endpoint with correct anyOf request serialization. Each CommitFile variant is serialized into the shape the API expects.

ยงErrors

Returns an error if the request fails or the response cannot be deserialized.