code: func (t *Tool) ParseArgs(args []string) {
  	args = t.parseFlags(args)
  
  	switch len(args) {
  	case 0:
  		args = []string{"."}
  		fallthrough
  
  	case 1:
  		info, err := os.Stat(args[0])
  		if err != nil {
  			fmt.Fprintln(os.Stderr, err)
  			os.Exit(2)
  		}
  		if info.IsDir() {
  			t.Dir = args[0]
  			t.FileNames, err = goFilesIn(args[0])
  			if err != nil {
  				fmt.Fprintln(os.Stderr, err)
  				os.Exit(2)
  			}
  			break
  		}
  		fallthrough
  
  	default:
  		t.Dir = filepath.Dir(args[0])
  		t.FileNames = args
  	}
  }
docs: // ParseArgs parses command arguments. Exits if they are invalid.