From da95c4ee8f19759c08183f3111f79c5e96e25dbe Mon Sep 17 00:00:00 2001 From: garret Date: Sun, 20 Nov 2022 04:24:02 +0000 Subject: feedmaker: metadata getter: move what i can to before the loadfile() nothing is sacred after that point no sense in risking stuff changing when i could just move it up a bit --- make-feed.lua | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'make-feed.lua') diff --git a/make-feed.lua b/make-feed.lua index 8cbc58b..07f3609 100755 --- a/make-feed.lua +++ b/make-feed.lua @@ -74,6 +74,8 @@ local function get_metadata(file) -- having all those nils in the table doesn't really do anything in terms of functionality, but it lets me see what i need to put in it meta.filename = file + meta.sha1 = sha1.sha1(readfile(file)) + meta.release = get_iso8601_date(lfs.attributes(file, "modification")) loadfile(file)() -- script_name etc are now in our global scope @@ -84,8 +86,6 @@ local function get_metadata(file) meta.author = script_author meta.namespace = script_namespace meta.depctrl = __feedmaker_version - meta.sha1 = sha1.sha1(readfile(file)) - meta.release = get_iso8601_date(lfs.attributes(file, "modification")) return meta end -- cgit v1.2.3-70-g09d2