Skip to content

Instantly share code, notes, and snippets.

@nhtua
Created August 7, 2015 09:45
Show Gist options
  • Save nhtua/414cc8f15865f30d0fe2 to your computer and use it in GitHub Desktop.
Save nhtua/414cc8f15865f30d0fe2 to your computer and use it in GitHub Desktop.
Convert multiple fonts to woff
#! /bin/bash
#Put this file into woff tool's dir, which was compiled before
#To convert multiple file, type:
# ./run_woff.sh /path/to/fonts/dir <format(otf|ttf)>
fontdir=$1
fontext=$2
files=($fontdir/*.$2)
for item in ${files[*]}
do
./sfnt2woff $item
printf "Convert %s to woff success. \n" $item
done
printf "Convert completed\n"
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment