From df7ec5a70f0effd1c7749392a86c3d7adaf83364 Mon Sep 17 00:00:00 2001 From: Benjamin Franzke Date: Mon, 4 Jul 2016 07:26:37 +0200 Subject: Add git hash as query string to resources ..to be able to set an infinite cache for the browser, but to invalidate the resources for every git commit (That may be a waste of resources, but is "most safe" to ensure we get an up to date site) It has to be explicitly defined in the template. Occurences of the img-tag in the source files get the git hash automatically appended. --- Makefile | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'Makefile') diff --git a/Makefile b/Makefile index a36830b..01cb9b0 100644 --- a/Makefile +++ b/Makefile @@ -1,6 +1,7 @@ suffix = .xhtml +version = $(shell git rev-parse --short HEAD) -xsltproc=xsltproc --stringparam suffix $(suffix) --stringparam stylesheet style.min.css +xsltproc=xsltproc --stringparam suffix $(suffix) --stringparam stylesheet style.min.css --stringparam version $(version) svg2png=rsvg-convert -f png pages=$(shell xsltproc xsl/main_filenames.xsl main.xml) -- cgit