From 82aafbca62ded6977fd70ab4d21e514f6374106d Mon Sep 17 00:00:00 2001 From: Aoran Zeng Date: Sun, 10 Aug 2025 12:26:09 +0800 Subject: [PATCH] Update chef DSL --- src/framework/chef.c | 13 ++++++++++++- 1 file changed, 12 insertions(+), 1 deletion(-) diff --git a/src/framework/chef.c b/src/framework/chef.c index a570433..9a60381 100644 --- a/src/framework/chef.c +++ b/src/framework/chef.c @@ -7,7 +7,7 @@ * Created On : <2025-08-09> * Last Modified : <2025-08-10> * - * For chefs (recipe makers) to define a target + * chef DSL: for chefs (recipe makers) to define a target * ------------------------------------------------------------*/ #pragma once @@ -71,6 +71,17 @@ chef_forbid_user_define (Target_t *target) } +void +chef_set_note (Target_t *target, const char *note_zh, const char *note_en) +{ + if (!target || !note) + return; + + char *msg = CHINESE ? xy_strdup(note_zh) : xy_strdup(note_en); + target->note = msg; +} + + void chef_set_contributors (Target_t *target, uint32_t count, ...) {