From 57bcec6cac7535c4cb06814c95a92ffd23fddc06 Mon Sep 17 00:00:00 2001 From: "Rafael G. Martins" Date: Sat, 25 Feb 2017 23:22:09 +0100 Subject: make: keep backward compatibility with [copy_files] --- src/blogc-make/settings.c | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) (limited to 'src') diff --git a/src/blogc-make/settings.c b/src/blogc-make/settings.c index 0e80807..50092ac 100644 --- a/src/blogc-make/settings.c +++ b/src/blogc-make/settings.c @@ -72,6 +72,7 @@ static const char* list_sections[] = { "posts", "pages", "copy", + "copy_files", // backward compatibility "tags", NULL, }; @@ -160,9 +161,13 @@ bm_settings_parse(const char *content, size_t content_len, bc_error_t **err) rv->posts = bc_config_get_list(config, "posts"); rv->pages = bc_config_get_list(config, "pages"); - rv->copy = bc_config_get_list(config, "copy"); rv->tags = bc_config_get_list(config, "tags"); + // this is for backward compatibility too. + rv->copy = bc_config_get_list(config, "copy"); + if (rv->copy == NULL) + rv->copy = bc_config_get_list(config, "copy_files"); + cleanup: bc_config_free(config); -- cgit v1.2.3-18-g5258