Struct brush_shell::CommandLineArgs
source · pub struct CommandLineArgs {Show 21 fields
pub help: Option<bool>,
pub version: Option<bool>,
pub command: Option<String>,
pub interactive: bool,
pub login: bool,
pub do_not_execute_commands: bool,
pub no_editing: bool,
pub no_profile: bool,
pub no_rc: bool,
pub enabled_shopt_options: Vec<String>,
pub disabled_shopt_options: Vec<String>,
pub posix: bool,
pub read_commands_from_stdin: bool,
pub sh_mode: bool,
pub verbose: bool,
pub print_commands_and_arguments: bool,
pub disable_bracketed_paste: bool,
pub input_backend: Option<InputBackend>,
pub enabled_log_events: Vec<TraceEvent>,
pub script_path: Option<String>,
pub script_args: Vec<String>,
}Expand description
Parsed command-line arguments for the brush shell.
Fields§
§help: Option<bool>Display usage information.
version: Option<bool>Display shell version.
command: Option<String>Execute the provided command and then exit.
interactive: boolRun in interactive mode.
login: boolMake shell act as if it had been invoked as a login shell.
do_not_execute_commands: boolDo not execute commands.
no_editing: boolDon’t use readline for input.
no_profile: boolDon’t process any profile/login files (/etc/profile, ~/.bash_profile, ~/.bash_login,
~/.profile).
no_rc: boolDon’t process “rc” files if the shell is interactive (e.g., ~/.bashrc, ~/.brushrc).
enabled_shopt_options: Vec<String>Enable shell option.
disabled_shopt_options: Vec<String>Disable shell option.
posix: boolDisable non-POSIX extensions.
read_commands_from_stdin: boolRead commands from standard input.
sh_mode: boolRun in sh compatibility mode.
verbose: boolPrint input when it’s processed.
print_commands_and_arguments: boolPrint commands as they execute.
disable_bracketed_paste: boolDisable bracketed paste.
input_backend: Option<InputBackend>Input backend.
enabled_log_events: Vec<TraceEvent>Enable debug logging for classes of tracing events.
script_path: Option<String>Path to script to execute.
script_args: Vec<String>Arguments for script.
Implementations§
source§impl CommandLineArgs
impl CommandLineArgs
pub fn is_interactive(&self) -> bool
Trait Implementations§
source§impl Args for CommandLineArgs
impl Args for CommandLineArgs
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 CommandFactory for CommandLineArgs
impl CommandFactory for CommandLineArgs
source§impl FromArgMatches for CommandLineArgs
impl FromArgMatches for CommandLineArgs
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.source§impl Parser for CommandLineArgs
impl Parser for CommandLineArgs
source§fn parse_from<I, T>(itr: I) -> Self
fn parse_from<I, T>(itr: I) -> Self
source§fn try_parse_from<I, T>(itr: I) -> Result<Self, Error>
fn try_parse_from<I, T>(itr: I) -> Result<Self, Error>
source§fn update_from<I, T>(&mut self, itr: I)
fn update_from<I, T>(&mut self, itr: I)
Auto Trait Implementations§
impl Freeze for CommandLineArgs
impl RefUnwindSafe for CommandLineArgs
impl Send for CommandLineArgs
impl Sync for CommandLineArgs
impl Unpin for CommandLineArgs
impl UnwindSafe for CommandLineArgs
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> 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