#[non_exhaustive]pub enum CliError {
Show 109 variants
Import(String),
NoThumbnail(String),
Exists(PathBuf),
NotInLibrary,
NoLibraryIn(PathBuf),
NoAccess(PathBuf, Error),
NoDefaultLibrary(PathBuf),
RelativeDefault(PathBuf),
Unfinished(PathBuf),
IsCopy(PathBuf),
NoSecretsInCopies,
NoCopy(PathBuf),
SeveralCopies(PathBuf),
CopiedHere(PathBuf),
NoJournal(PathBuf),
UncleanRemoval(PathBuf),
InLibraryData(PathBuf),
NoCurrentFolder(Error),
Languages(ParseLanguagesError),
NoForms,
OneAlready {
entity: String,
into: String,
},
NothingMerged(String),
WhichMerged {
entity: String,
candidates: String,
},
NotMergedInto {
entity: String,
other: String,
},
NoHistory(String),
Moment(String),
NotYet {
entity: String,
when: String,
},
PassphrasesDiffer,
Stale(PathBuf),
FilesFailed(usize),
NotFetched {
name: String,
holders: Vec<String>,
},
NotGiven {
name: String,
holders: Vec<String>,
},
SyncsFailed(usize),
NotAnswered(String),
NotAnAiAgent,
UnknownAiClient(String),
NoTerminal,
ValuesDiffer,
EmptyValue,
SecretField(FieldName),
SecretGiven(FieldName),
SecretHistory(FieldName),
SecretFolder(PathBuf),
SecretFileCheckout(String),
NotSecret(FieldName),
Generator(GeneratorError),
OneTime(OneTimeError),
Clipboard(ClipboardError),
RecipeWithoutGenerate,
GeneratedOneTimeCode(FieldName),
NoRule(String),
WhereTo,
NoSecrets,
NoSecretValue {
entity: String,
field: FieldName,
},
EmptyPassphrase,
PassphraseFile {
path: PathBuf,
error: Error,
},
PassphraseFileOpen(PathBuf),
AtLoginPassphrase,
NoStateFolder,
NoSyncProgram,
NoKeystore,
Keystore(NodeError),
NoKeystoreToProtect,
KeystoreToProtect(NodeError),
Name(String),
StandardName {
name: String,
what: &'static str,
},
Field(String),
Kind {
kind: String,
kinds: String,
},
Flag(String),
Flags(String),
NoType(TypeName),
AmbiguousType {
name: String,
candidates: String,
},
NoField {
field: String,
types: String,
},
AmbiguousField {
field: String,
candidates: String,
},
TypeSet,
Assignment(String),
Unsound(usize),
UnsoundExport(usize),
Unconfirmed,
UnconfirmedMove,
UnconfirmedStart,
NoGitCommit(PathBuf),
NotInTree(PathBuf),
NoTreeHere(PathBuf),
NoLibraryForTree(PathBuf),
BadPointer {
file: PathBuf,
why: String,
},
StrayPointer {
file: PathBuf,
library: PathBuf,
},
ThroughPointer(PathBuf),
PointerInTheWay(PathBuf),
PointerNotWritten {
file: PathBuf,
error: Error,
},
PointerNotTakenAway {
file: PathBuf,
error: Error,
},
NoAccountName,
NoSuchCommand {
verb: &'static str,
instead: &'static str,
},
RevertTakesRevision(String),
UnconfirmedRevoke,
NewSpacesElsewhere(String),
NotARecoveryCode,
StillUnlocks,
UnknownRecoveryCode,
UnconfirmedAccept,
UnconfirmedLeave,
UnconfirmedRemove,
UnconfirmedClaim,
UnconfirmedInvite,
SetAndCleared(FieldName),
Value {
field: FieldName,
expected: &'static str,
},
Ambiguous {
reference: String,
count: usize,
candidates: String,
},
Node(NodeError),
Io(Error),
}Expand description
Why a command failed.
Variants (Non-exhaustive)§
This enum is marked as non-exhaustive
Import(String)
An archive to import could not be read, or held nothing to import.
NoThumbnail(String)
A file has no thumbnail, as its device could not read its format, or it is no picture.
Exists(PathBuf)
Something is where a file would be written, which replaces nothing.
NotInLibrary
No library was given, and the current folder is in none.
NoLibraryIn(PathBuf)
The folder given as the library holds none.
NoAccess(PathBuf, Error)
The system lets nib not read a folder where a library would be, as macOS does with a removable drive until the person allows the terminal to reach it.
NoDefaultLibrary(PathBuf)
NIBKEEP_LIBRARY names a folder that holds no library.
RelativeDefault(PathBuf)
NIBKEEP_LIBRARY names a folder relative to the current one.
Unfinished(PathBuf)
A library’s .nib holds what is left of starting it, in this replica’s folder.
IsCopy(PathBuf)
A library’s .nib holds only copies of replicas made elsewhere, which are never used
as the devices they were (technical design: copies of a replica).
NoSecretsInCopies
nib secret from-copy found no secrets keys in the copies, or the person left the
passphrase of the copy’s secrets empty.
NoCopy(PathBuf)
nib recovery from-copy finds no copy in the library’s .nib.
SeveralCopies(PathBuf)
nib recovery from-copy finds several copies, of which it would not know which to use.
CopiedHere(PathBuf)
A library’s .nib holds only copies of replicas made elsewhere, so a new library is
not started there.
NoJournal(PathBuf)
A library would be on a drive without a journal, which the person did not allow (technical design: drives without a journal).
UncleanRemoval(PathBuf)
The drive of a library without a journal was removed, or lost its power, while the library was open.
InLibraryData(PathBuf)
A library would be started in what another library keeps.
NoCurrentFolder(Error)
The current folder cannot be found.
Languages(ParseLanguagesError)
Ranked languages that cannot be read.
NoForms
--form without forms to add or remove.
OneAlready
Entities to merge that are one already.
Fields
NothingMerged(String)
A merge to undo, of an entity that nothing was merged into.
WhichMerged
A merge to undo, of one of several entities merged into another, not said which.
NotMergedInto
A merge to undo, of an entity that was not merged into the one given.
Fields
NoHistory(String)
A field that an entity never had, in nib history.
Moment(String)
A moment that cannot be used.
NotYet
An entity shown as recorded by a moment, when the library had no record of it yet.
PassphrasesDiffer
The passphrase and its confirmation differ.
Stale(PathBuf)
The edits of a checkout’s copy, made to a version that is no longer the file’s own.
FilesFailed(usize)
Files that could not be added, while the others were.
NotFetched
A file to check out that this device lacks, which none of the devices that hold it gave, as none was found on the network.
NotGiven
A file to check out that this device lacks, which the devices that hold it, as their accounts say, did not give, though a sync reached them.
SyncsFailed(usize)
Devices that could not be synced with, while the others were.
NotAnswered(String)
The program that syncs this device did not answer nib sync in time.
NotAnAiAgent
nib mcp on a library that neither allows AI agents nor is an AI agent’s.
UnknownAiClient(String)
--client names no AI client that nib mcp enable knows.
NoTerminal
nib mcp on a library whose keys need a passphrase, without a file that holds it.
ValuesDiffer
A secret value and its confirmation differ.
EmptyValue
A secret value to set is empty.
SecretField(FieldName)
A secret field, in a command that takes no secret values.
SecretGiven(FieldName)
A value of a secret field given on the command line, which shells keep.
SecretHistory(FieldName)
The history of a secret field, which nib history leaves out.
SecretFolder(PathBuf)
A folder given to nib file add --secret, which takes files one by one.
SecretFileCheckout(String)
A secret file to check out, of which NibKeep records no copies.
NotSecret(FieldName)
A field that is not secret, in nib secret.
Generator(GeneratorError)
A password that cannot be generated as asked.
OneTime(OneTimeError)
A secret of one-time codes that makes none.
Clipboard(ClipboardError)
The clipboard failed.
RecipeWithoutGenerate
Options for a generated password, without –generate.
GeneratedOneTimeCode(FieldName)
A generated secret of one-time codes, which only the site can give.
NoRule(String)
A rule that no number or ID names.
WhereTo
A rule to move, without saying where.
NoSecrets
Secrets to unlock, in a library that has none.
NoSecretValue
A secret field without values, in nib secret show.
EmptyPassphrase
The passphrase is empty.
PassphraseFile
The file that gives the passphrase cannot be read.
PassphraseFileOpen(PathBuf)
The file that gives the passphrase can be read by others.
AtLoginPassphrase
Syncing from login, for a library whose keys a passphrase protects.
NoStateFolder
No home folder to keep the list of libraries synced from login in.
NoSyncProgram
No nibkeep-sync beside nib.
NoKeystore
The library’s keys are in the platform’s keystore, which is not there.
Keystore(NodeError)
The platform’s keystore failed while a library was started.
NoKeystoreToProtect
No keystore to protect a library’s keys or its secrets with.
KeystoreToProtect(NodeError)
The platform’s keystore failed while protecting a library’s keys or its secrets.
Name(String)
A name is not valid.
StandardName
A name that a person gives is a standard one, which only the standard vocabulary gives, so that a later version’s standard field never meets another kind of it.
Field(String)
A field is not given as name:kind.
Kind
There is no such kind of value.
Flag(String)
There is no such flag for a field.
Flags(String)
A field’s flags contradict each other, or repeat.
NoType(TypeName)
There is no such type.
AmbiguousType
Several types end in the name.
NoField
The types have no such field.
AmbiguousField
Several fields of the types end in the name.
TypeSet
Types set, or cleared, rather than given or taken away one by one.
Assignment(String)
A value is not given as field=value.
Unsound(usize)
Checking the library found something wrong.
UnsoundExport(usize)
An export that differs from the library, with how many problems were found.
Unconfirmed
A purge was not confirmed.
UnconfirmedMove
A move of a folder or a list, with all it holds, was not confirmed.
UnconfirmedStart
Starting a tree was not confirmed.
NoGitCommit(PathBuf)
Pinning a folder that holds no Git repository with a commit.
NotInTree(PathBuf)
A tree’s command run outside every tree’s folder on this device.
NoTreeHere(PathBuf)
A command that reads a tree’s history run outside every tree’s folder on this device, with no tree named.
NoLibraryForTree(PathBuf)
nib init given a folder, a message or –yes, to make a tree, where neither that folder
nor the current one is in a library.
BadPointer
A .nib file in a folder that names no library nib may open.
StrayPointer
A .nib file that names a library which keeps no tree in that folder on this device, as
a copy of a tree’s folder would.
ThroughPointer(PathBuf)
A command about the library’s place, run where only a tree’s .nib file names the
library.
PointerInTheWay(PathBuf)
Something other than a file where the .nib file of a tree outside the library’s
folder goes.
PointerNotWritten
The .nib file of a tree outside the library’s folder could not be written.
PointerNotTakenAway
The .nib file of a tree inside the library’s folder, which would take over the
commands there, could not be deleted.
NoAccountName
nib init without –name, where the system names no account to name the user after.
NoSuchCommand
A command of other version control systems that nib does not have.
RevertTakesRevision(String)
nib revert given a path, as Mercurial’s revert takes, rather than a revision.
UnconfirmedRevoke
A revocation was not confirmed.
NewSpacesElsewhere(String)
Whether another device takes new spaces, which only that device says.
NotARecoveryCode
What was typed was no recovery code, each time it was asked for.
StillUnlocks
A recovery in place of a library here that still unlocks with the keystore, which it would only revoke.
UnknownRecoveryCode
The recovery code typed is none that the library names.
UnconfirmedAccept
Accepting changes that were set aside was not confirmed.
UnconfirmedLeave
Leaving a space was not confirmed.
UnconfirmedRemove
Removing a member was not confirmed.
UnconfirmedClaim
Claiming the admin role was not confirmed.
UnconfirmedInvite
An invitation without –yes, where there is no terminal to ask whether to add whoever asks.
SetAndCleared(FieldName)
A field is set and cleared in one edit.
Value
A value cannot be read as its field’s kind says.
Ambiguous
A name or a prefix of an ID that several entities have.
Fields
Node(NodeError)
The engine failed.
Io(Error)
Reading or writing failed.
Trait Implementations§
Source§impl Error for CliError
impl Error for CliError
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<ClipboardError> for CliError
impl From<ClipboardError> for CliError
Source§fn from(source: ClipboardError) -> Self
fn from(source: ClipboardError) -> Self
Source§impl From<GeneratorError> for CliError
impl From<GeneratorError> for CliError
Source§fn from(source: GeneratorError) -> Self
fn from(source: GeneratorError) -> Self
Source§impl From<OneTimeError> for CliError
impl From<OneTimeError> for CliError
Source§fn from(source: OneTimeError) -> Self
fn from(source: OneTimeError) -> Self
Source§impl From<ParseLanguagesError> for CliError
impl From<ParseLanguagesError> for CliError
Source§fn from(source: ParseLanguagesError) -> Self
fn from(source: ParseLanguagesError) -> Self
Source§impl From<PointerError> for CliError
What is wrong with a .nib file, as nib says it.
impl From<PointerError> for CliError
What is wrong with a .nib file, as nib says it.
Source§fn from(error: PointerError) -> Self
fn from(error: PointerError) -> Self
Auto Trait Implementations§
impl !RefUnwindSafe for CliError
impl !UnwindSafe for CliError
impl Forget for CliError
impl Freeze for CliError
impl Move for CliError
impl Send for CliError
impl Sync for CliError
impl Unpin for CliError
impl UnsafeUnpin for CliError
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
impl<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
Source§impl<T> Downcast for Twhere
T: Any,
impl<T> Downcast for Twhere
T: Any,
Source§fn into_any(self: Box<T>) -> Box<dyn Any>
fn into_any(self: Box<T>) -> Box<dyn Any>
Box<dyn Trait> (where Trait: Downcast) to Box<dyn Any>. Box<dyn Any> can
then be further downcast into Box<ConcreteType> where ConcreteType implements Trait.Source§fn into_any_rc(self: Rc<T>) -> Rc<dyn Any>
fn into_any_rc(self: Rc<T>) -> Rc<dyn Any>
Rc<Trait> (where Trait: Downcast) to Rc<Any>. Rc<Any> can then be
further downcast into Rc<ConcreteType> where ConcreteType implements Trait.Source§fn as_any(&self) -> &(dyn Any + 'static)
fn as_any(&self) -> &(dyn Any + 'static)
&Trait (where Trait: Downcast) to &Any. This is needed since Rust cannot
generate &Any’s vtable from &Trait’s.Source§fn as_any_mut(&mut self) -> &mut (dyn Any + 'static)
fn as_any_mut(&mut self) -> &mut (dyn Any + 'static)
&mut Trait (where Trait: Downcast) to &Any. This is needed since Rust cannot
generate &mut Any’s vtable from &mut Trait’s.