pub struct CommonParams {
pub provider: Option<String>,
pub model: Option<String>,
pub instructions: Option<String>,
pub preset: Option<String>,
pub gitmoji_flag: bool,
pub no_gitmoji: bool,
pub critic_flag: bool,
pub no_critic: bool,
pub gitmoji: Option<bool>,
pub critic: Option<bool>,
pub repository_url: Option<String>,
}Fields§
§provider: Option<String>Override default LLM provider
model: Option<String>Override model for this operation
instructions: Option<String>Custom instructions for this operation
preset: Option<String>Select an instruction preset
gitmoji_flag: boolEnable Gitmoji (default: true)
no_gitmoji: boolDisable Gitmoji
critic_flag: boolEnable critic verification pass
no_critic: boolDisable critic verification pass
gitmoji: Option<bool>Internal: resolved gitmoji value (Some(true), Some(false), or None)
critic: Option<bool>Internal: resolved critic value (Some(true), Some(false), or None)
repository_url: Option<String>Repository URL to use instead of local repository
Implementations§
Source§impl CommonParams
impl CommonParams
Sourcepub fn resolved_gitmoji(&self) -> Option<bool>
pub fn resolved_gitmoji(&self) -> Option<bool>
Get the resolved gitmoji value from CLI flags Returns Some(true) for –gitmoji, Some(false) for –no-gitmoji, None if neither specified
Sourcepub fn resolved_critic(&self) -> Option<bool>
pub fn resolved_critic(&self) -> Option<bool>
Get the resolved critic value from CLI flags Returns Some(true) for –critic, Some(false) for –no-critic, None if neither specified
Sourcepub fn apply_to_config(&self, config: &mut Config) -> Result<bool>
pub fn apply_to_config(&self, config: &mut Config) -> Result<bool>
§Errors
Returns an error when the requested provider is invalid.
Sourcepub fn is_valid_preset_for_type(&self, preset_type: PresetType) -> bool
pub fn is_valid_preset_for_type(&self, preset_type: PresetType) -> bool
Check if the provided preset is valid for the specified preset type
Trait Implementations§
Source§impl Args for CommonParams
impl Args for CommonParams
Source§fn augment_args<'b>(__clap_app: Command) -> Command
fn augment_args<'b>(__clap_app: Command) -> Command
Source§fn augment_args_for_update<'b>(__clap_app: Command) -> Command
fn augment_args_for_update<'b>(__clap_app: Command) -> Command
Command so it can instantiate self via
FromArgMatches::update_from_arg_matches_mut Read moreSource§impl Clone for CommonParams
impl Clone for CommonParams
Source§fn clone(&self) -> CommonParams
fn clone(&self) -> CommonParams
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreSource§impl Debug for CommonParams
impl Debug for CommonParams
Source§impl Default for CommonParams
impl Default for CommonParams
Source§fn default() -> CommonParams
fn default() -> CommonParams
Source§impl FromArgMatches for CommonParams
impl FromArgMatches for CommonParams
Source§fn from_arg_matches(__clap_arg_matches: &ArgMatches) -> Result<Self, Error>
fn from_arg_matches(__clap_arg_matches: &ArgMatches) -> Result<Self, Error>
Source§fn from_arg_matches_mut(
__clap_arg_matches: &mut ArgMatches,
) -> Result<Self, Error>
fn from_arg_matches_mut( __clap_arg_matches: &mut ArgMatches, ) -> Result<Self, Error>
Source§fn update_from_arg_matches(
&mut self,
__clap_arg_matches: &ArgMatches,
) -> Result<(), Error>
fn update_from_arg_matches( &mut self, __clap_arg_matches: &ArgMatches, ) -> Result<(), Error>
ArgMatches to self.Source§fn update_from_arg_matches_mut(
&mut self,
__clap_arg_matches: &mut ArgMatches,
) -> Result<(), Error>
fn update_from_arg_matches_mut( &mut self, __clap_arg_matches: &mut ArgMatches, ) -> Result<(), Error>
ArgMatches to self.Auto Trait Implementations§
impl Freeze for CommonParams
impl RefUnwindSafe for CommonParams
impl Send for CommonParams
impl Sync for CommonParams
impl Unpin for CommonParams
impl UnsafeUnpin for CommonParams
impl UnwindSafe for CommonParams
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
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> 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>
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>
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