diff options
author | garret <garret@airmail.cc> | 2022-11-26 00:05:49 +0000 |
---|---|---|
committer | garret <garret@airmail.cc> | 2022-11-26 00:05:49 +0000 |
commit | 409ca1f18a5d6c1bc1f96224508a1437d97f3ed0 (patch) | |
tree | 8f3ce00c03fbe99705e8cbf33ab36c359ccdec2d | |
parent | f8a6f32b14cc1333450a72da758c601d3da09a78 (diff) | |
download | depctrl-feedmaker-409ca1f18a5d6c1bc1f96224508a1437d97f3ed0.tar.gz depctrl-feedmaker-409ca1f18a5d6c1bc1f96224508a1437d97f3ed0.tar.bz2 depctrl-feedmaker-409ca1f18a5d6c1bc1f96224508a1437d97f3ed0.zip |
feedmaker: use different fileBaseUrls for modules/macros
-rwxr-xr-x | make-feed.lua | 9 |
1 files changed, 7 insertions, 2 deletions
diff --git a/make-feed.lua b/make-feed.lua index 1c5e619..77faa41 100755 --- a/make-feed.lua +++ b/make-feed.lua @@ -107,7 +107,7 @@ local function get_macro_metadata(file) loadfile(file)() -- script_name etc are now in our global scope - if config.macroIgnoreCondition() then + if config.macros.ignoreCondition() then err(file .. ": ignored by config, skipping") return nil end @@ -127,7 +127,7 @@ local function get_module_metadata(file) meta.sha1, meta.release = get_file_metadata(file) loadfile(file)() -- script_name etc are now in our global scope - if config.moduleIgnoreCondition() then + if config.modules.ignoreCondition() then err(file .. ": ignored by config, skipping") return nil end @@ -188,6 +188,11 @@ local function make_feed(meta) feed.knownFeeds = join_ktables(feed.knownFeeds, feeds) feed.modules[script.namespace] = mod end + + config.macros.ignoreCondition = nil config.modules.ignoreCondition = nil + -- remove the functions so they don't cause problems with the json conversion + feed.macros = join_ktables(feed.macros, config.macros) + feed.modules = join_ktables(feed.modules, config.modules) return json.encode(feed) end |