update .gitignore
fix some bugs & add some new functions
add extern APIs
edit test