From 0dfc3ef5bdc131cb79404522ce8fbd4bfccb40a1 Mon Sep 17 00:00:00 2001 From: daimond113 <72147841+daimond113@users.noreply.github.com> Date: Sat, 18 Jan 2025 15:14:58 +0100 Subject: [PATCH] fix: scope CAS package indices to index of package Fixes conflicts between multiple packages with the same name in different indices. --- src/source/pesde/mod.rs | 1 + src/source/wally/mod.rs | 1 + 2 files changed, 2 insertions(+) diff --git a/src/source/pesde/mod.rs b/src/source/pesde/mod.rs index 7c31d7f..b52349a 100644 --- a/src/source/pesde/mod.rs +++ b/src/source/pesde/mod.rs @@ -197,6 +197,7 @@ impl PackageSource for PesdePackageSource { let index_file = project .cas_dir() .join("index") + .join(hash(self.as_bytes())) .join(id.name().escaped()) .join(id.version_id().version().to_string()) .join(id.version_id().target().to_string()); diff --git a/src/source/wally/mod.rs b/src/source/wally/mod.rs index 5e24815..445ec53 100644 --- a/src/source/wally/mod.rs +++ b/src/source/wally/mod.rs @@ -229,6 +229,7 @@ impl PackageSource for WallyPackageSource { let index_file = project .cas_dir() .join("wally_index") + .join(hash(self.as_bytes())) .join(id.name().escaped()) .join(id.version_id().version().to_string());