@@ -4,7 +4,7 @@ mod sources;
44
55use anyhow:: { Context , Result , bail} ;
66use std:: {
7- collections:: BTreeMap ,
7+ collections:: HashMap ,
88 fs,
99 path:: { Path , PathBuf } ,
1010 process:: Command ,
@@ -18,7 +18,7 @@ use crate::{
1818use hash:: calc_build_hash;
1919use sources:: get_sources;
2020
21- #[ derive( serde:: Deserialize , serde:: Serialize , Clone , Hash ) ]
21+ #[ derive( serde:: Deserialize , serde:: Serialize , Clone ) ]
2222struct BuildManifest {
2323 /// ID of this package, the main alias
2424 id : String ,
@@ -46,11 +46,10 @@ struct BuildManifest {
4646 /// Useful for SDKs.
4747 sdks : Option < Vec < String > > ,
4848 /// RUNTIME environment variables
49- /// This is a `BTreeMap` due to `HashMap` not having the `hash` trait.
50- env : Option < BTreeMap < String , String > > ,
49+ env : Option < HashMap < String , String > > ,
5150}
5251
53- #[ derive( serde:: Deserialize , serde:: Serialize , Clone , Hash ) ]
52+ #[ derive( serde:: Deserialize , serde:: Serialize , Clone ) ]
5453struct Source {
5554 /// Should either be git, tar or local
5655 kind : String ,
@@ -199,7 +198,7 @@ fn include_all(
199198 build_dir : & Path ,
200199 repo_path : & Path ,
201200 chunk_store_path : & Path ,
202- envs : & mut BTreeMap < String , String > ,
201+ envs : & mut HashMap < String , String > ,
203202) -> Result < ( ) > {
204203 for dependency in packages {
205204 let result = include (
@@ -224,7 +223,7 @@ fn include(
224223 path_to_include_at : & Path ,
225224 repo_path : & Path ,
226225 chunk_store_path : & Path ,
227- ) -> Result < BTreeMap < String , String > > {
226+ ) -> Result < HashMap < String , String > > {
228227 let dependency_build_manifest_path = search_path. join ( dependency) ;
229228 let dependency_build_manifest: BuildManifest =
230229 serde_yaml:: from_str ( & fs:: read_to_string ( dependency_build_manifest_path) ?) ?;
0 commit comments