 (defun govc (command &rest args)
   "Execute govc COMMAND with ARGS.
 Return value is `buffer-string' split on newlines."
-  (govc-process (govc-command command args)
+  (govc-process (govc-format-command command args)
                 (lambda ()
                   (split-string (buffer-string) "\n" t))))
 
 (defun govc-json (command &rest args)
   "Execute govc COMMAND passing arguments ARGS.
 Return value is `json-read'."
-  (govc-process (govc-command command (cons "-json" args))
+  (govc-process (govc-format-command command (cons "-json" args))
                 (lambda ()
                   (goto-char (point-min))
                   (let ((json-object-type 'plist))

  "Events via govc events -n `govc-max-events'."
  (interactive)
  (govc-shell-command
   (govc-command "events"
                 (list "-n" govc-max-events (if current-prefix-arg "-f") (govc-selection)))))

(defun govc-parse-info (output)
  "Parse govc info command OUTPUT."

    (if url
        (or (url-target url) (url-host url)))))

(defun govc-format-command (command &rest args)
  "Format govc COMMAND ARGS."
  (format "%s %s %s" govc-command command
          (s-join " " (--map (format "'%s'" it)
                             (-flatten (-non-nil args))))))

