Skip to content

Commit

Permalink
Add start_commit_id to ListLabelHistoryRequest (#81)
Browse files Browse the repository at this point in the history
To view a diff for a commit on a label we need to be able to get the
previous commit on that label. Added `start_commit_id` so we can fetch
the history starting at the desired commit and using a page size of 2
can also get the previous commit.
  • Loading branch information
nicksnyder authored Mar 4, 2024
1 parent 4b63e53 commit 3e01648
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 0 deletions.
4 changes: 4 additions & 0 deletions buf/registry/module/v1/label_service.proto
Original file line number Diff line number Diff line change
Expand Up @@ -160,6 +160,10 @@ message ListLabelHistoryRequest {
//
// If not set, Commits with any CommitCheckStatus value are returned.
repeated CommitCheckStatus commit_check_statuses = 6 [(buf.validate.field).repeated.items.enum.defined_only = true];
// The Commit id to start from.
//
// It is an error to provide a Commit id that doesn't exist on the Label.
string start_commit_id = 7 [(buf.validate.field).string.uuid = true];
}

message ListLabelHistoryResponse {
Expand Down
4 changes: 4 additions & 0 deletions buf/registry/module/v1beta1/label_service.proto
Original file line number Diff line number Diff line change
Expand Up @@ -168,6 +168,10 @@ message ListLabelHistoryRequest {
//
// If not set, Commits with any CommitCheckStatus value are returned.
repeated CommitCheckStatus commit_check_statuses = 6 [(buf.validate.field).repeated.items.enum.defined_only = true];
// The Commit id to start from.
//
// It is an error to provide a Commit id that doesn't exist on the Label.
string start_commit_id = 7 [(buf.validate.field).string.uuid = true];
}

message ListLabelHistoryResponse {
Expand Down

0 comments on commit 3e01648

Please sign in to comment.