#[non_exhaustive]pub enum PackageFormat {
All,
Default,
App,
Dmg,
Wix,
Nsis,
Deb,
AppImage,
Pacman,
}
Expand description
Types of supported packages by cargo-packager
.
Variants (Non-exhaustive)§
This enum is marked as non-exhaustive
Non-exhaustive enums could have additional variants added in future. Therefore, when matching against variants of non-exhaustive enums, an extra wildcard arm must be added to account for any future variants.
All
All available package formats for the current platform.
Default
The default list of package formats for the current platform.
App
The macOS application bundle (.app).
Dmg
The macOS DMG package (.dmg).
Wix
The Microsoft Software Installer (.msi) through WiX Toolset.
Nsis
The NSIS installer (.exe).
Deb
The Linux Debian package (.deb).
AppImage
The Linux AppImage package (.AppImage).
Pacman
The Linux Pacman package (.tar.gz and PKGBUILD)
Implementations§
Source§impl PackageFormat
impl PackageFormat
Sourcepub fn from_short_name(name: &str) -> Option<PackageFormat>
pub fn from_short_name(name: &str) -> Option<PackageFormat>
Maps a short name to a PackageFormat. Possible values are “deb”, “pacman”, “appimage”, “dmg”, “app”, “wix”, “nsis”.
Sourcepub fn short_name(&self) -> &'static str
pub fn short_name(&self) -> &'static str
Gets the short name of this PackageFormat.
Sourcepub fn platform_all() -> &'static [PackageFormat]
pub fn platform_all() -> &'static [PackageFormat]
Gets the list of the possible package types on the current OS.
- macOS: App, Dmg
- Windows: Nsis, Wix
- Linux: Deb, AppImage, Pacman
Sourcepub fn platform_default() -> &'static [PackageFormat]
pub fn platform_default() -> &'static [PackageFormat]
Returns the default list of targets this platform
- macOS: App, Dmg
- Windows: Nsis
- Linux: Deb, AppImage, Pacman
Trait Implementations§
Source§impl Clone for PackageFormat
impl Clone for PackageFormat
Source§fn clone(&self) -> PackageFormat
fn clone(&self) -> PackageFormat
Returns a copy of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source
. Read moreSource§impl Debug for PackageFormat
impl Debug for PackageFormat
Source§impl<'de> Deserialize<'de> for PackageFormat
impl<'de> Deserialize<'de> for PackageFormat
Source§fn deserialize<__D>(
__deserializer: __D,
) -> Result<PackageFormat, <__D as Deserializer<'de>>::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(
__deserializer: __D,
) -> Result<PackageFormat, <__D as Deserializer<'de>>::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Source§impl Display for PackageFormat
impl Display for PackageFormat
Source§impl PartialEq for PackageFormat
impl PartialEq for PackageFormat
Source§impl Serialize for PackageFormat
impl Serialize for PackageFormat
Source§fn serialize<__S>(
&self,
__serializer: __S,
) -> Result<<__S as Serializer>::Ok, <__S as Serializer>::Error>where
__S: Serializer,
fn serialize<__S>(
&self,
__serializer: __S,
) -> Result<<__S as Serializer>::Ok, <__S as Serializer>::Error>where
__S: Serializer,
Serialize this value into the given Serde serializer. Read more
Source§impl ValueEnum for PackageFormat
impl ValueEnum for PackageFormat
Source§fn value_variants<'a>() -> &'a [PackageFormat]
fn value_variants<'a>() -> &'a [PackageFormat]
All possible argument values, in display order.
Source§fn to_possible_value<'a>(&self) -> Option<PossibleValue>
fn to_possible_value<'a>(&self) -> Option<PossibleValue>
The canonical argument value. Read more
impl Copy for PackageFormat
impl Eq for PackageFormat
impl StructuralPartialEq for PackageFormat
Auto Trait Implementations§
impl Freeze for PackageFormat
impl RefUnwindSafe for PackageFormat
impl Send for PackageFormat
impl Sync for PackageFormat
impl Unpin for PackageFormat
impl UnwindSafe for PackageFormat
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
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
Compare self to
key
and return true
if they are equal.Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self
into a Left
variant of Either<Self, Self>
if into_left
is true
.
Converts self
into a Right
variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self
into a Left
variant of Either<Self, Self>
if into_left(&self)
returns true
.
Converts self
into a Right
variant of Either<Self, Self>
otherwise. Read more