impl Repo and md5-cache reading
This commit is contained in:
@@ -7,6 +7,7 @@ use crate::{
|
||||
};
|
||||
|
||||
pub mod parsers;
|
||||
pub mod repo;
|
||||
|
||||
#[derive(Clone, Debug)]
|
||||
pub enum Conditional {
|
||||
@@ -23,10 +24,28 @@ pub enum Depend<T> {
|
||||
ConditionalGroup(Conditional, Vec<Self>),
|
||||
}
|
||||
|
||||
#[derive(Debug, Clone)]
|
||||
pub enum UriPrefix {
|
||||
Mirror,
|
||||
Fetch,
|
||||
}
|
||||
|
||||
#[derive(Debug, Clone, Get)]
|
||||
pub struct SrcUri {
|
||||
uri: String,
|
||||
file_name: Option<PathBuf>,
|
||||
pub struct Uri {
|
||||
#[get(kind = "deref")]
|
||||
protocol: String,
|
||||
#[get(kind = "deref")]
|
||||
path: String,
|
||||
}
|
||||
|
||||
#[derive(Debug, Clone)]
|
||||
pub enum SrcUri {
|
||||
Filename(PathBuf),
|
||||
Uri {
|
||||
prefix: Option<UriPrefix>,
|
||||
uri: Uri,
|
||||
filename: Option<PathBuf>,
|
||||
},
|
||||
}
|
||||
|
||||
#[derive(Debug, Clone, Get)]
|
||||
@@ -44,14 +63,22 @@ pub struct Ebuild {
|
||||
version: Version,
|
||||
slot: Option<Slot>,
|
||||
homepage: Option<String>,
|
||||
#[get(kind = "deref")]
|
||||
src_uri: Vec<Depend<SrcUri>>,
|
||||
eapi: Option<Eapi>,
|
||||
#[get(kind = "deref")]
|
||||
inherit: Vec<Eclass>,
|
||||
#[get(kind = "deref")]
|
||||
iuse: Vec<IUseFlag>,
|
||||
#[get(kind = "deref")]
|
||||
license: Vec<Depend<License>>,
|
||||
description: Option<String>,
|
||||
#[get(kind = "deref")]
|
||||
depend: Vec<Depend<Atom>>,
|
||||
#[get(kind = "deref")]
|
||||
bdepend: Vec<Depend<Atom>>,
|
||||
rdpened: Vec<Depend<Atom>>,
|
||||
#[get(kind = "deref")]
|
||||
rdepend: Vec<Depend<Atom>>,
|
||||
#[get(kind = "deref")]
|
||||
idepend: Vec<Depend<Atom>>,
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user