change dir for cpp and lua