api: Implement vim_command_output function

This function can be used by API clients to execute a command and capture the
output.
fix 'sign unplace id'

Since the introduction of the FOR_ALL_BUFFERS macro, 'sign unplace id'
without a buffer was only removing the sign from the first buffer rather
than all buffers, as described in the documentation.

  :help sign-unplace