handle command prompt