#[non_exhaustive]pub enum TargetError {
Show 18 variants
NotFound {
dir: Utf8PathBuf,
},
Nested {
dir: Utf8PathBuf,
root: Utf8PathBuf,
},
OldConfig,
NoSuchSource {
name: SourceName,
sources: Vec<SourceName>,
layers: Vec<ProfileRef>,
},
SourceExists {
name: SourceName,
location: String,
},
WhichSource {
profile: ProfileName,
sources: Vec<SourceName>,
},
Ambiguous {
location: String,
profiles: Vec<ProfileName>,
},
DuplicateLayer {
layer: ProfileName,
},
LayerTwice {
layer: ProfileName,
},
NotListed {
layer: ProfileName,
feature: FeatureName,
listed: Vec<FeatureName>,
},
NoSuchLayer {
name: String,
names: Vec<String>,
},
NoSuchScaffold {
name: String,
scaffolds: Vec<String>,
},
NotManaged {
path: String,
managed: Vec<RelPath>,
},
Required {
name: ProfileName,
by: ProfileName,
},
StaleOverride {
path: RelPath,
provided: Vec<RelPath>,
},
NotAFile {
path: RelPath,
kind: &'static str,
},
Busy,
Concurrent,
}Expand description
Why a target cannot be found, read or written.
Variants (Non-exhaustive)§
This enum is marked as non-exhaustive
NotFound
No directory from here up holds .devset/config.toml.
Fields
dir: Utf8PathBufWhere the search began.
Nested
A new target would lie inside another.
OldConfig
config.toml is devset 0.1’s: its layers name locations, not profiles.
NoSuchSource
A layer, or a command, names a source [sources] does not.
Fields
name: SourceNameThe name asked for.
sources: Vec<SourceName>Every source’s name.
layers: Vec<ProfileRef>The layers config.toml names it for.
SourceExists
[sources] already names another source so.
WhichSource
A profile is named without its source, and the target names several, or none.
Ambiguous
A source holds several profiles, and none was named.
Fields
profiles: Vec<ProfileName>Every profile it holds.
DuplicateLayer
config.toml already lists the layer.
Fields
layer: ProfileNameThe layer’s profile.
LayerTwice
config.toml lists one layer twice, which a layer’s name must tell apart.
Fields
layer: ProfileNameThe layer’s profile.
NotListed
A feature to turn off that the layer does not list.
Fields
layer: ProfileNameThe layer’s profile.
feature: FeatureNameThe feature.
listed: Vec<FeatureName>The features the layer lists.
NoSuchLayer
No layer, and no source, has the name asked for.
NoSuchScaffold
A scaffold named on the command line is no active profile’s.
Fields
NotManaged
A path named on the command line is not a file devset manages.
Required
A layer named where only a configured one will do is one another profile requires.
StaleOverride
config.toml overrides a path no layer provides.
NotAFile
A managed path on disk is a symlink, a directory or a special file.
Fields
Busy
Another devset holds the target’s lock.
Concurrent
state.toml changed while this devset ran.
Trait Implementations§
Source§impl Clone for TargetError
impl Clone for TargetError
Source§impl Debug for TargetError
impl Debug for TargetError
Source§impl Display for TargetError
impl Display for TargetError
impl Eq for TargetError
Source§impl Error for TargetError
impl Error for TargetError
1.30.0 · Source§fn source(&self) -> Option<&(dyn Error + 'static)>
fn source(&self) -> Option<&(dyn Error + 'static)>
1.0.0 · Source§fn description(&self) -> &str
fn description(&self) -> &str
use the Display impl or to_string()
Source§impl From<TargetError> for Error
impl From<TargetError> for Error
Source§fn from(source: TargetError) -> Self
fn from(source: TargetError) -> Self
Source§impl PartialEq for TargetError
impl PartialEq for TargetError
impl StructuralPartialEq for TargetError
Auto Trait Implementations§
impl Freeze for TargetError
impl RefUnwindSafe for TargetError
impl Send for TargetError
impl Sync for TargetError
impl Unpin for TargetError
impl UnsafeUnpin for TargetError
impl UnwindSafe for TargetError
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<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
key and return true if they are equal.