NAME

Pithub::Repos::Commits

VERSION

version 0.01000

METHODS

create_comment

  • Create a commit comment

    POST /repos/:user/:repo/commits/:sha/comments

Examples:

$result = $p->repos->commits->create_comment(
    user => 'plu',
    repo => 'Pithub',
    sha  => 'df21b2660fb6',
    data => { body => 'some comment' },
);

delete_comment

  • Delete a commit comment

    DELETE /repos/:user/:repo/comments/:id

Examples:

$result = $p->repos->commits->delete_comment(
    user       => 'plu',
    repo       => 'Pithub',
    comment_id => 1,
);

get

  • Get a single commit

    GET /repos/:user/:repo/commits/:sha

Examples:

$result = $p->repos->commits->get(
    user => 'plu',
    repo => 'Pithub',
    sha  => 'df21b2660fb6',
);

get_comment

  • Get a single commit comment

    GET /repos/:user/:repo/comments/:id

Examples:

$result = $p->repos->commits->get_comment(
    user       => 'plu',
    repo       => 'Pithub',
    comment_id => 1,
);

list

  • List commits on a repository

    GET /repos/:user/:repo/commits

Examples:

$result = $p->repos->commits->list(
    user => 'plu',
    repo => 'Pithub',
);

list_comments

  • List commit comments for a repository

    Commit Comments leverage these custom mime types. You can read more about the use of mimes types in the API here. TODO: Link github API

    GET /repos/:user/:repo/comments

    Examples:

    $result = $p->repos->commits->list_comments(
        user => 'plu',
        repo => 'Pithub',
    );
  • List comments for a single commit

    GET /repos/:user/:repo/commits/:sha/comments

Examples:

$result = $p->repos->commits->list_comments(
    user => 'plu',
    repo => 'Pithub',
    sha  => 'df21b2660fb6',
);

update_comment

  • Update a commit comment

    PATCH /repos/:user/:repo/comments/:id

Examples:

$result = $p->repos->commits->update_comment(
    user       => 'plu',
    repo       => 'Pithub',
    comment_id => 1,
    data       => { body => 'updated comment' },
);