pub struct KimiCodeAuth {
pub credentials_path: PathBuf,
pub lock_target: PathBuf,
}Expand description
The two paths inside a kimi-code home this vendor touches: the credential
file it reads and rewrites, and the lock target that serializes a refresh
against the CLI’s own (see lock.rs).
Fields§
§credentials_path: PathBuf§lock_target: PathBufImplementations§
Source§impl KimiCodeAuth
impl KimiCodeAuth
pub fn in_home(home: &Path) -> Self
Sourcepub fn with_credentials_path(home: &Path, credentials_path: PathBuf) -> Self
pub fn with_credentials_path(home: &Path, credentials_path: PathBuf) -> Self
A credential file relocated by config ([kimi] credentials_path) still
belongs to a kimi-code home; the lock target is derived from that home
so both clients agree on which file the lock protects.
Trait Implementations§
Source§impl Clone for KimiCodeAuth
impl Clone for KimiCodeAuth
Source§fn clone(&self) -> KimiCodeAuth
fn clone(&self) -> KimiCodeAuth
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreAuto Trait Implementations§
impl Freeze for KimiCodeAuth
impl RefUnwindSafe for KimiCodeAuth
impl Send for KimiCodeAuth
impl Sync for KimiCodeAuth
impl Unpin for KimiCodeAuth
impl UnsafeUnpin for KimiCodeAuth
impl UnwindSafe for KimiCodeAuth
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,
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
Source§fn in_current_span(self) -> Instrumented<Self> ⓘ
fn in_current_span(self) -> Instrumented<Self> ⓘ
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more