[][src]Struct quickcfg::opts::Opts

pub struct Opts {
    pub root: Option<PathBuf>,
    pub init: Option<String>,
    pub paths: bool,
    pub force: bool,
    pub updates_only: bool,
    pub debug: bool,
    // some fields omitted
}

A set of parsed options.

Fields

root: Option<PathBuf>

The root at which the project is running from.

init: Option<String>

Initialize the project from the given repo.

paths: bool

Print paths used by quickcfg.

force: bool

Force update.

updates_only: bool

Only run if there are updates to the repo.

debug: bool

Enable debug logging.

Methods

impl Opts[src]

pub fn root(&self, base_dirs: Option<&BaseDirs>) -> Result<PathBuf, Error>[src]

Find root directory based on options.

pub fn prompt(&self, question: &str, default: bool) -> Result<bool, Error>[src]

Prompt for yes/no.

pub fn input(&self, prompt: &str) -> Result<Option<String>, Error>[src]

Prompt for input.

Trait Implementations

impl Default for Opts[src]

Auto Trait Implementations

impl RefUnwindSafe for Opts

impl Send for Opts

impl Sync for Opts

impl Unpin for Opts

impl UnwindSafe for Opts

Blanket Implementations

impl<T> Any for T where
    T: 'static + ?Sized
[src]

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

impl<T> From<T> for T[src]

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.