From fb27e8ed5030e6b5aa8df33cc4d347eacaef76ba Mon Sep 17 00:00:00 2001 From: "Rafael G. Martins" Date: Fri, 24 Feb 2017 23:15:28 +0100 Subject: make: parse runserver arguments from cli, instead of env this is some over-optimized parser, to celebrate #cloudbleed :D --- src/blogc-make/rules.h | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) (limited to 'src/blogc-make/rules.h') diff --git a/src/blogc-make/rules.h b/src/blogc-make/rules.h index b39e7be..7a15d45 100644 --- a/src/blogc-make/rules.h +++ b/src/blogc-make/rules.h @@ -15,7 +15,7 @@ typedef bc_slist_t* (*bm_rule_outputlist_func_t) (bm_ctx_t *ctx); typedef int (*bm_rule_exec_func_t) (bm_ctx_t *ctx, bc_slist_t *outputs, - bool verbose); + bc_trie_t *args, bool verbose); typedef struct { const char *name; @@ -25,8 +25,10 @@ typedef struct { bool generate_files; } bm_rule_t; +bc_trie_t* bm_rule_parse_args(const char *sep); int bm_rule_executor(bm_ctx_t *ctx, bc_slist_t *rule_list, bool verbose); -int bm_rule_execute(bm_ctx_t *ctx, const bm_rule_t *rule, bool verbose); +int bm_rule_execute(bm_ctx_t *ctx, const bm_rule_t *rule, bc_trie_t *args, + bool verbose); bool bm_rule_need_rebuild(bc_slist_t *sources, bm_filectx_t *settings, bm_filectx_t *template, bm_filectx_t *output, bool only_first_source); bc_slist_t* bm_rule_list_built_files(bm_ctx_t *ctx); -- cgit v1.2.3-18-g5258