Fixed bugs, added cd terminal option