#[derive(Clone, Debug, thiserror::Error, PartialEq, Eq)]
pub enum Invalid {
#[error(
"`{0}` isn't a pack's name: `@scope/name`, each part lowercase letters, digits, `-`, `.`, `_` and `~`, not starting with `.` or `_`"
)]
Name(String),
#[error("`{0}` isn't a release: a pack's name, `@` and a version (`@kit/mermaid@1.2.0`)")]
Release(String),
#[error(
"`{0}` isn't a file's path in a pack: `/`-separated names, none of them empty, `.` or `..`, with no `\\` or `:`"
)]
Path(String),
#[error("`{0}` isn't an integrity: `sha256-`, `sha384-` or `sha512-` and a digest, in base64")]
Integrity(String),
}