From 554a94f8fd5815b165847af586f9c99ad7981485 Mon Sep 17 00:00:00 2001 From: Johannes Löthberg Date: Tue, 15 Nov 2016 14:13:29 +0100 Subject: build: Prepare for tags by making build_archive a bit more generic MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: Johannes Löthberg --- scripts/build.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'scripts') diff --git a/scripts/build.py b/scripts/build.py index 4533513..e029052 100755 --- a/scripts/build.py +++ b/scripts/build.py @@ -24,10 +24,10 @@ def build_entry(jenv, fname, entry, older=None, newer=None): f.write(rendered) -def build_archive(jenv, entries): +def build_archive(jenv, filename, entries): archive_template = jenv.get_template('archive.html') rendered = archive_template.render(entries=entries) - with open('out/archive.html', 'w+') as f: + with open('out/{}.html'.format(filename), 'w+') as f: f.write(rendered) @@ -70,4 +70,4 @@ if __name__ == '__main__': build_entry(jenv, 'index', published[-1], older=published[-2:-1]) - build_archive(jenv, published) + build_archive(jenv, 'archive', published) -- cgit v1.2.3-70-g09d2