summaryrefslogtreecommitdiffstats
path: root/crates/driver/src/recipe.rs
diff options
context:
space:
mode:
Diffstat (limited to 'crates/driver/src/recipe.rs')
-rw-r--r--crates/driver/src/recipe.rs2
1 files changed, 2 insertions, 0 deletions
diff --git a/crates/driver/src/recipe.rs b/crates/driver/src/recipe.rs
index aa728c8..16d3751 100644
--- a/crates/driver/src/recipe.rs
+++ b/crates/driver/src/recipe.rs
@@ -146,6 +146,8 @@ pub fn read_recipes<P: AsRef<Path>>(path: P) -> Result<HashMap<TaskID, Vec<TaskD
for entry in WalkDir::new(path)
.sort_by(|a, b| {
+ // Files are sorted first by stem, then by extension, so that
+ // recipe.yml will always be read before recipe.NAME.yml
let stem_cmp = a.path().file_stem().cmp(&b.path().file_stem());
let ext_cmp = a.path().extension().cmp(&b.path().extension());
stem_cmp.then(ext_cmp)