feat: added command functionality to install

This commit is contained in:
Strix 2023-10-14 22:39:43 +02:00
parent 3a21d12c07
commit 092c616ca4
No known key found for this signature in database
GPG key ID: 49B2E37B8915B774
20 changed files with 464 additions and 76 deletions

View file

@ -1,8 +1,24 @@
#[derive(Debug)]
pub struct PKGFile {
pub manifest: String,
pub data: Vec<u8>,
}
impl PKGFile {
pub fn new(manifest: String, data: Vec<u8>) -> PKGFile {
PKGFile { manifest, data }
}
}
impl Default for PKGFile {
fn default() -> PKGFile {
PKGFile {
manifest: String::new(),
data: Vec::new(),
}
}
}
impl TryFrom<Vec<u8>> for PKGFile {
type Error = ();