Use cmd.go for the console. Reworked flag parsing.