This commit is contained in:
parent
e488955e7a
commit
4d3c50c5fc
3 changed files with 6 additions and 13 deletions
|
@ -19,7 +19,7 @@ pub struct Package {
|
|||
pub arch: Architecture,
|
||||
/// Name of the package
|
||||
pub name: String,
|
||||
pub rel: i32,
|
||||
pub rel: String,
|
||||
/// Version of the package
|
||||
pub version: Option<String>,
|
||||
/// Compression used
|
||||
|
@ -33,7 +33,7 @@ impl Package {
|
|||
arch: Architecture,
|
||||
pkg_name: &str,
|
||||
version: &str,
|
||||
rel: i32,
|
||||
rel: String,
|
||||
compression: Compression,
|
||||
) -> Self {
|
||||
let pkg = Package {
|
||||
|
@ -49,7 +49,7 @@ impl Package {
|
|||
pkg
|
||||
}
|
||||
|
||||
pub fn version(ver: &str) -> (String, i32) {
|
||||
pub fn version(ver: &str) -> (String, String) {
|
||||
let mut splitted = ver.split('-').collect::<Vec<_>>();
|
||||
let rel = splitted.pop().unwrap();
|
||||
let ver = splitted.join("-");
|
||||
|
@ -226,7 +226,7 @@ impl Package {
|
|||
repo: repo.to_string(),
|
||||
arch,
|
||||
name: pkg_name.to_string(),
|
||||
rel: 1,
|
||||
rel: 1.to_string(),
|
||||
version: None,
|
||||
compression,
|
||||
};
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue