Skip to content

Instantly share code, notes, and snippets.

@mfo
Last active April 30, 2016 08:12
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save mfo/55e96603b58d3ebc20d182acd8bb9f15 to your computer and use it in GitHub Desktop.
Save mfo/55e96603b58d3ebc20d182acd8bb9f15 to your computer and use it in GitHub Desktop.
zopfli on snap-ci
# make zopfli
pushd .
git clone https://github.com/google/zopfli.git zopfli-build && cd zopfli-build && make
export PATH="$PATH:$(pwd)"
popd
# after assets precompile, zopfli all of them [nproc/sysctl -n hw.ncpu for compat btw centos & macox]
find public/assets | grep -E '.*\.(css|js)$' | xargs -P $(if [ $(which nproc) ]; then nproc; else sysctl -n hw.ncpu; fi;) zopfli
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment