#[non_exhaustive]pub struct ForgePr {
pub number: u64,
pub title: String,
pub state: ForgePrState,
pub source_branch: String,
pub target_branch: String,
pub url: String,
pub draft: bool,
}Expand description
A pull request (GitHub) / merge request (GitLab) / pull request (Gitea), unified across the three forges.
Fields (Non-exhaustive)§
This struct is marked as non-exhaustive
Non-exhaustive structs could have additional fields added in future. Therefore, non-exhaustive structs cannot be constructed in external crates using the traditional
Struct { .. } syntax; cannot be matched against without a wildcard ..; and struct update syntax will not work.number: u64The PR/MR number a caller passes to the other operations (GitHub/Gitea
number, GitLab iid).
title: StringTitle.
state: ForgePrStateNormalised state (see ForgePrState).
source_branch: StringSource (head) branch name.
target_branch: StringTarget (base) branch name.
url: StringWeb URL.
draft: boolWhether the PR/MR is a draft. Best-effort: only GitLab reports it on
the lean surface; GitHub and Gitea report false here (their lean JSON
doesn’t carry the draft flag).
Trait Implementations§
impl Eq for ForgePr
impl StructuralPartialEq for ForgePr
Auto Trait Implementations§
impl Freeze for ForgePr
impl RefUnwindSafe for ForgePr
impl Send for ForgePr
impl Sync for ForgePr
impl Unpin for ForgePr
impl UnsafeUnpin for ForgePr
impl UnwindSafe for ForgePr
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