Added simple semantic version comparison for dependecy checking
parent
9c582d1257
commit
44778f91c3
|
|
@ -1,4 +1,5 @@
|
||||||
use std::{
|
use std::{
|
||||||
|
cmp::Ordering::*,
|
||||||
env::var,
|
env::var,
|
||||||
path::{Path, PathBuf},
|
path::{Path, PathBuf},
|
||||||
process::Command,
|
process::Command,
|
||||||
|
|
|
||||||
|
|
@ -111,7 +111,7 @@ fn sort_by_dependencies(mods: &Vec<ModInfo>) -> Vec<ModInfo> {
|
||||||
mod_info.dependencies.iter().all(|dependency| {
|
mod_info.dependencies.iter().all(|dependency| {
|
||||||
resolved_mods
|
resolved_mods
|
||||||
.iter()
|
.iter()
|
||||||
.any(|resolved| *dependency == resolved.dependency_string())
|
.any(|resolved| resolved.satisfies(dependency))
|
||||||
})
|
})
|
||||||
})
|
})
|
||||||
.map(|(index, _)| index);
|
.map(|(index, _)| index);
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue