version merge

from the one ripped from jingyi.me