Struct tugger_debian::DebBuilder[][src]

pub struct DebBuilder<'control> { /* fields omitted */ }

A builder for a .deb package file.

Implementations

impl<'control> DebBuilder<'control>[src]

pub fn new(control_file: ControlFile<'control>) -> Self[src]

Construct a new instance using a control file.

pub fn set_compression(self, compression: DebCompression) -> Self[src]

Set the compression format to use.

Not all compression formats are supported by all Linux distributions.

pub fn set_mtime(self, time: Option<SystemTime>) -> Self[src]

Set the modified time to use on archive members.

If this is called, all archive members will use the specified time, helping to make archive content deterministic.

If not called, the current time will be used.

pub fn extra_control_tar_file(
    self,
    path: impl AsRef<Path>,
    entry: impl Into<FileEntry>
) -> Result<Self, DebError>
[src]

Add an extra file to the control.tar archive.

pub fn install_file(
    self,
    path: impl AsRef<Path> + Clone,
    entry: impl Into<FileEntry> + Clone
) -> Result<Self, DebError>
[src]

Register a file as to be installed by this package.

Filenames should be relative to the filesystem root. e.g. usr/bin/myapp.

The file content will be added to the data.tar archive and registered with the control.tar archive so its checksum is computed.

pub fn write<W: Write>(&self, writer: &mut W) -> Result<(), DebError>[src]

Write .deb file content to a writer.

This effectively materialized the .deb package somewhere.

Auto Trait Implementations

impl<'control> RefUnwindSafe for DebBuilder<'control>

impl<'control> Send for DebBuilder<'control>

impl<'control> Sync for DebBuilder<'control>

impl<'control> Unpin for DebBuilder<'control>

impl<'control> UnwindSafe for DebBuilder<'control>

Blanket Implementations

impl<T> Any for T where
    T: 'static + ?Sized
[src]

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

impl<T> From<T> for T[src]

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.