refactor: always use target names in packages folders

This commit is contained in:
daimond113 2024-09-28 23:46:09 +02:00
parent bc86c2f1c5
commit 863a09ef65
No known key found for this signature in database
GPG key ID: 3A8ECE51328B513C

View file

@ -75,9 +75,12 @@ impl TargetKind {
/// The folder to store packages in for this target /// The folder to store packages in for this target
/// self is the project's target, dependency is the target of the dependency /// self is the project's target, dependency is the target of the dependency
pub fn packages_folder(&self, dependency: &Self) -> String { pub fn packages_folder(&self, dependency: &Self) -> String {
if self == dependency { // the code below might seem better, but it's just going to create issues with users trying
return "packages".to_string(); // to use a build script, since imports would break between targets
}
// if self == dependency {
// return "packages".to_string();
// }
format!("{dependency}_packages") format!("{dependency}_packages")
} }