comment out \usepackage[T1]{fontenc}

This could cause some font error in Chinese.
use bash instead of purely sh

The brain-damaged Ubuntu link /bin/sh to dash, which is not feature
complete. Cope with it.