#[repr(u8)]pub enum Forge {
Forgejo = 0,
GitHub = 1,
}Expand description
Supported forges.
Variants§
Implementations§
Source§impl Forge
impl Forge
Sourcepub const fn default_url(self) -> Option<&'static str>
pub const fn default_url(self) -> Option<&'static str>
Default API base used when a caller does not provide an override.
Forgejo has no single default host, unlike GitHub’s one API, so a
Forgejo caller without an explicit forge URL gets None rather than a
guess.
Sourcepub const fn git_username(self) -> &'static str
pub const fn git_username(self) -> &'static str
The username that pairs with a token for HTTP Git access.
The Authorization header value of the forge’s Cargo registry.
Forgejo wants a Bearer scheme and GitHub takes the raw token.
Trait Implementations§
impl Copy for Forge
impl Eq for Forge
impl StructuralPartialEq for Forge
Auto Trait Implementations§
impl Freeze for Forge
impl RefUnwindSafe for Forge
impl Send for Forge
impl Sync for Forge
impl Unpin for Forge
impl UnsafeUnpin for Forge
impl UnwindSafe for Forge
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to
key and return true if they are equal.