match input commands