Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Fetching contributors…

Cannot retrieve contributors at this time

53 lines (36 sloc) 1.296 kB
# helpers
RSYNC_EXCLUDES = --exclude 'src' --exclude '.DS_Store' --exclude '.gitignore' --exclude '.hgignore'
# input
JADE_DIR = jade
#JADE_PARTIALS = $(shell find $(JADE_DIR)/templates/partials/*.jade)
JADE_PAGES = $(shell find $(JADE_DIR)/*.jade)
JS_IN_DIR = js
JS_FILES = $(shell find $(JS_IN_DIR)/ -type f -name '*.js')
# output
OUT_DIR = build
STATIC_IN_DIR = static
STATIC_OUT_DIR = $(OUT_DIR)
STATIC_FILES = $(shell find $(STATIC_IN_DIR) -type f)
HTML_OUT_DIR = $(OUT_DIR)
JS_OUT_DIR = $(OUT_DIR)/js
JS_CONCAT_FILES = $(shell find $(JS_IN_DIR)/*.js)
.PHONY: all
all: html css static_files rss
html:
./node_modules/.bin/quinoa jade
css: out/css/style.min.css
out/css/style.slim.css: $(shell find $(STATIC_OUT_DIR) -type f -name '*.html') out/css/style.css
./node_modules/.bin/uncss --stylesheets css/style.css out/index.html > out/css/style.slim.css
out/css/style.min.css: out/css/style.slim.css
./node_modules/.bin/cleancss --s0 < out/css/style.slim.css > out/css/style.min.css
rss:
node rss.js
static_files: $(STATIC_FILES)
rsync -vaz $(RSYNC_EXCLUDES) $(STATIC_IN_DIR)/ $(STATIC_OUT_DIR)
#$(HTML_OUT_DIR)/%.html: %.jade
# jade --path $(JADE_DIR) --out $(HTML_OUT_DIR) $<
$(JS_OUT_DIR)/%.js: $(JS_IN_DIR)/%.js
@mkdir -p "$(@D)"
cp $< $@
clean:
rm -rf $(OUT_DIR)/*
Jump to Line
Something went wrong with that request. Please try again.