Running console commands via code.