fixing bug introduced by a refactor
adding rudimentary tab-complete