pub struct NewOptions {
pub type_name: String,
pub slug: Option<String>,
pub id: Option<String>,
pub title: Option<String>,
pub seq: Option<u64>,
pub states: Vec<(String, String)>,
pub dir: Option<PathBuf>,
pub for_asset: Option<PathBuf>,
pub cwd: PathBuf,
pub write: bool,
pub id_only: bool,
pub cache: CacheMode,
}Expand description
NewOptions holds the options of sokf new.
Fields§
§type_name: Stringtype_name is the value of TYPE.
slug: Option<String>slug is the value of --slug.
id: Option<String>id is the value of --id.
title: Option<String>title is the value of --title.
seq: Option<u64>seq is the value of --seq, the sequence number that the id takes
in place of the next one.
states: Vec<(String, String)>states holds the values of --state, each a key and a state, in the
order of the arguments.
dir: Option<PathBuf>dir is the value of --dir, as a path in the repository or a path
relative to cwd.
for_asset: Option<PathBuf>for_asset is the value of --for, as a path in the repository or a
path relative to cwd.
cwd: PathBufcwd is the current directory, from which a relative --dir or
--for resolves.
write: boolwrite is true when the command has --write.
id_only: boolid_only is true when the command has --id-only.
cache: CacheModecache is the cache mode.
Trait Implementations§
Source§impl Clone for NewOptions
impl Clone for NewOptions
Auto Trait Implementations§
impl Forget for NewOptions
impl Freeze for NewOptions
impl Move for NewOptions
impl RefUnwindSafe for NewOptions
impl Send for NewOptions
impl Sync for NewOptions
impl Unpin for NewOptions
impl UnsafeUnpin for NewOptions
impl UnwindSafe for NewOptions
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