Skip to content

Instantly share code, notes, and snippets.

@BrianHicks
Created January 20, 2016 21:52
Show Gist options
  • Save BrianHicks/ac5228e5ca6a8ce8454d to your computer and use it in GitHub Desktop.
Save BrianHicks/ac5228e5ca6a8ce8454d to your computer and use it in GitHub Desktop.
all: public
static/css/asteris.css: scss/*.scss scss/**/*.scss
sass -t compressed --scss scss/asteris.scss static/css/asteris.css
public: config.yaml archetypes/**/* content/**/* layouts/**/* static/**/* static/css/asteris.css
hugo
uncss -C public/css -H public $$(find public -name '*.html') | cleancss > public/css/asteris.min.css
mv public/css/asteris.min.css public/css/asteris.css
jpegoptim --strip-all --totals --csv --max 70 $$(find public -name '*.jp*g')
optipng -quiet -o 7 $$(find public -name '*.png')
# PHONIES
watch-scss:
sass --scss --watch scss/asteris.scss:static/css/asteris.css
watch-content:
hugo server -w
.PHONY: all watch-scss watch-content
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment