From 74f353bea50895bee0f95cb8771ca43119e7436b Mon Sep 17 00:00:00 2001 From: Benjamin Franzke Date: Sun, 3 Jul 2016 21:38:03 +0200 Subject: Postcss (for css3 variables) and minify our stylesshet We do need a css3 variable transformation for internet explorer. We do check in the minifed sourcecode into git. We don't want to have to install node_modules on our deployment server. Note that the *.xml files opened directly in the browser will not use the minified, but the original stylesheet (thus there's no need for a watcher script while development) --- Makefile | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) (limited to 'Makefile') diff --git a/Makefile b/Makefile index 4fc5526..ecfe00f 100644 --- a/Makefile +++ b/Makefile @@ -1,13 +1,13 @@ suffix = .xhtml -xsltproc=xsltproc --stringparam suffix $(suffix) +xsltproc=xsltproc --stringparam suffix $(suffix) --stringparam stylesheet style.min.css svg2png=rsvg-convert -f png pages=$(shell xsltproc xsl/main_filenames.xsl main.xml) pages_gen=$(pages:%.xml=%$(suffix)) -common_depend=main.xml $(wildcard xsl/*.xsl) +common_depend=main.xml $(wildcard xsl/*.xsl) Makefile DEFAULT_VERBOSITY=0 @@ -32,5 +32,8 @@ all: $(pages_gen) checkmark.png %$(suffix): %.xml $(common_depend) $(V_XSLT) $(xsltproc) $< > $@ +style/style.min.css: style/style.css + node_modules/.bin/postcss -u postcss-css-variables style/style.css | node_modules/.bin/cleancss > style/style.min.css + clean: rm -f $(pages_gen) checkmark.png -- cgit